This is a migrated thread and some comments may be shown as answers.

[Solved] setSize problem after postback

1 Answer 99 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Niclas Ahlqvist
Top achievements
Rank 1
Niclas Ahlqvist asked on 16 Feb 2010, 04:07 PM
Hi!

Ive made some js functions that resizes the editor when the browser window is resized.

Everything works great until theres a postback. After the postback setSize throws an exception all the time.

The line casuing the exception is. (located in a scriptresource)
ln:5694  c.style.height="";  (c is null)


My code:
var bw_currenteditor;
//function to set editor variable called from editor.OnClientLoad
function contentTemplateEditorInit(editor) {
bw_currenteditor = editor;
}

//function to resize which is called from body.onresize
function ResizeTemplateEditor(editor) {

if (!editor || typeof editor.setSize != "function")
        return;
//Get new editor width and height
var h = Math.abs(BWgetContentControlPreviewWindowHeight() - 160);
var w = Math.abs(BWgetContentControlPreviewWindowWidth() - 40);
editor.setSize(w, h);
}

1 Answer, 1 is accepted

Sort by
0
Dobromir
Telerik team
answered on 18 Feb 2010, 01:25 PM
Hi Niclas,

I am afraid that the provided information is not enough for us to reproduce the problem. Could you please open a support ticket and attach a sample project that reproduce the issue so we can investigate it further?


All the best,
Dobromir
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
Editor
Asked by
Niclas Ahlqvist
Top achievements
Rank 1
Answers by
Dobromir
Telerik team
Share this question
or