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

Trying to Hide Dock on PageLoad get JS Error

1 Answer 59 Views
Dock
This is a migrated thread and some comments may be shown as answers.
James Van Buren
Top achievements
Rank 2
James Van Buren asked on 27 Mar 2009, 04:02 PM
Hello, i am trying to accomplish simple task by hiding a RadDock on PageLoad based on some logic.
I simply set radDock.visible=false
It does actually hides the DOCK but than when page continues to load i get this generic JS error

 
Microsoft JScript runtime error: 'undefined' is null or not an object  
 
pointing to this line
Sys.UI.VisibilityMode.registerEnum("Sys.UI.VisibilityMode");Sys.UI.Control=function(a){Sys.UI.Control.initializeBase(this);this._element=a;a.control=this

it's not the content inside of the dock, as i tried with no content, or simple one text line. Still same result.
I get an error and the whole DockLayout looses all of it's functionality, ie Drag&Drop, Expand and Colapse.
I tried Hiding code in different events (page_load, RadDockLayout1_Load, RadDockLayout1_LoadDockLayout,  RadDockLayout1_PreRender) it makes no difference.

This used to work in NoN Ajax.net version of doc and in 2008 Q1 version of the controls.
Please advise.

1 Answer, 1 is accepted

Sort by
0
Accepted
Denny
Top achievements
Rank 1
answered on 28 Mar 2009, 04:35 PM
Hi James,

I had the same problem. To fix the it, just replace "radDock.visible = False" into "radDock.closed = True".

Tags
Dock
Asked by
James Van Buren
Top achievements
Rank 2
Answers by
Denny
Top achievements
Rank 1
Share this question
or