asp.net 2.0 menu client script error '0.cells null'

D

denappel

Hi all,

We're currently developping an asp.net 2.0 project, and ran into a
problem with the new menu control.

At the first load of the page, no errors are generated, but after a
first postback an error pops up when hovering over a menu item:

"Error: '0.cells' is null or not an object"

the error is located in the client script function
function Menu_HideItems(items) {}

....
for(i = 0; i < rows[0].cells.length; i++) {
....
in this line the length of the rows array = 0, what generates an error.
the rows array should give the menu row, what fails here. A wrong item
is considered as the menu, and therefore gives an error.

When searching deeper it seems that the function

Has anyone had this kind of error with the menu control?
The controls' viewstate is enabled, that cannot be the problem.

Can I change the clientscript that is generated by the menu control to
avoid this error?

If anyone can help, that would be great!

tnx in advance,

Kind Regards,

Koen Appeltans
 
G

Guest

We are also getting the same error. This is our situation and how it
manifests:

Our web application uses an asp.net 2.0 menu and sitemap for navigation.
The page has an asp.net 2.0 treeview control on it. The data in the tree
view is built on the fly. A dhtml behavior is used to keep the selected item
in the treeview in about the middle of the screen(vertically). An Iframe is
used to display information about the item selected in the treeview or pages
selected from the menu.

the menu behaves as expected until the following conditions are met:
1 the mouse has been passed over the menu,
2 any item on the treeview is selected or expanded.
3 the mouse is pased over the menu again

We have noticed that the menu repositions itself 3px to the right of the
original position just before the above problem manifests.

The menu's will all drop down and will not disappear until the next
postback. The menu's will continue to lock down if the mouse is passed over
them until the page is refreshed.

The client scripting error that appears is "0.Cells is null or not an object"

Here is the page aspx:
<asp:panel id="PanelMenu" style="width: 840px; position: absolute; top:
64px; z-index: 5; left: 101px; height: 15px; background-color: transparent;"
runat="server">
<asp:menu id="MenuHSNOCertifications" runat="server"
datasourceid="SiteMapDataSource1" orientation="Horizontal"
staticdisplaylevels="2" style="z-index: 1; position: absolute;"
disappearafter="-1" enabletheming="False">
<staticmenustyle backcolor="Transparent" bordercolor="#739574"
horizontalpadding="5px" borderstyle="None" borderwidth="1px"
cssclass="HSNOMenu" />
<staticmenuitemstyle cssclass="HSNOMenu" />
<dynamicmenustyle backcolor="Transparent" bordercolor="#739574"
borderstyle="Dotted" borderwidth="1px" cssclass="HSNOMenu" />
<dynamicmenuitemstyle horizontalpadding="10px"
verticalpadding="2px" cssclass="HSNOMenu" />
<statichoverstyle backcolor="White" font-underline="True"
cssclass="HSNOMenu" />
<dynamichoverstyle cssclass="HSNOMenu" font-underline="True" />
<staticselectedstyle cssclass="HSNOMenu" />
<dynamicselectedstyle cssclass="HSNOMenu" />
</asp:menu>
<asp:sitemapdatasource id="SiteMapDataSource1" runat="server" />
</asp:panel>

<asp:TreeView ID="TreeViewHSNOLocations" runat="server"
NodeIndent="5" AutoGenerateDataBindings="false" EnableTheming="false"
PopulateNodesFromClient="False" style="width: 240px; height: 520px; z-index:
1; position: absolute; top:97px; left:10px;" nodewrap="True"
cssclass="ScrollingPanel" enableclientscript="False">
<hovernodestyle forecolor="CadetBlue" />
<selectednodestyle forecolor="Blue" />
</asp:TreeView>

<iframe id="FrameRight" name="FrameRight" runat="server" scrolling="no"
style="position:absolute; top:100px; left:256px; width:724px; height: 520px;
background-color: transparent; z-index: 3;" frameborder="0"></iframe>


Thanks in advance
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top