Register | Login

ZettaCube Forum and Knowledge Base

Welcome to ZettaCube forum. Here you can discuss various issues regarding our ZeeControls product. If you want to contact our developers directly, please email to support@zettacube.com.

Please register to post a message. Registration is immediate and free. Return users please login here.

 
  Forum  Knowledge Base  Run-Time Issues   Loading WebDock or WebSplitter in Ajax response, but not in initial page-load
Previous Previous
 
Next Next
New Post 1/5/2009 6:49 AM
  ZettaCube Support
64 posts
No Ranking


Loading WebDock or WebSplitter in Ajax response, but not in initial page-load 
Modified By ZettaCube Support  on 1/5/2009 6:50:19 AM)
If a WebDock or WebSplitter is not rendered to the browser in the initial page load, but is only rendered in a later Ajax response, then the external JavaScript files required by these controls may not be loaded.  As a result, the following JavaScript error will be thrown upon the Ajax response:
 
Error: 'ZC' is undefined
 
In IE, the message 'Error on page.' will be displayed at the lower left corner of the browser window.  You can double-click that message to examine the JavaScript error detail.
 
In Firefox or Google Chrome, no error message would be observed.  But the content of the panels within the WebDock or WebSplitter will appear to be stacked / packed, and the splitter bars will not be shown.
 
Workaround:
 
Add a dummy 0px by 0px WebDock or WebSplitterContainer so as to force the required JavaScript files to be loaded in initial page load.
 
If you are using WebDock, add the following to the end of the page, and outside of any UpdatePanel or controls:
<cc2:WebDock runat="server" ID="Dummy" Height="0px" Width="0px"></cc2:WebDock>
 
If you are using WebSplitter, add the following to the end of the page, and outside of any UpdatePanel or controls:
<cc2:WebSplitterContainer runat="server" ID="Dummy" Height="0px" Width="0px"></cc2:WebSplitterContainer>
 
 
Examples that can cause this problem:
 
  1. An UpdatePanel contains a Button and a WebSplitterContainer.  The WebSplitterContainer's Visible property is initially set to false. On Button clicked, the WebSplitterContainer's Visible property is set to true.  At run-time, when you click the button, the WebSplitterContainer is rendered upon Ajax response, but the required JavaScript files have not been loaded.
     
  2. An UpdatePanel contains a Wizard control.  A WebDock is added to step 2 of the Wizard. At run-time, when you advance to step 2, the WebDock is rendered upon Ajax response, but the required JavaScript files have not been loaded.
 
Previous Previous
 
Next Next
  Forum  Knowledge Base  Run-Time Issues   Loading WebDock or WebSplitter in Ajax response, but not in initial page-load
Copyright 2009 by ZettaCube Limited