This is a migrated thread and some comments may be shown as answers.
WebServiceSettings error
1 Answer 21 Views
This is a migrated thread and some comments may be shown as answers.
Dan
Top achievements
Rank 2
Dan asked on 08 Feb 2012, 09:52 PM
I've found what I think is a bug with the RadMenu control in the newest version of the RadControls (2011.3.1305). I had created a static RadMenu control (i.e. items defined at design time, using the smart tags) before the latest upgrade, and the generated code looked like this:

<telerik:RadMenu ID="RadMenu2" runat="server">
    <Items>
        <telerik:RadMenuItem runat="server" ImageUrl="..." Text="..." >
            <Items>
                <telerik:RadMenuItem runat="server" ImageUrl="..." Text="..." NavigateUrl="...">
                </telerik:RadMenuItem>
                [... several more items ...]
            </Items>
        </telerik:RadMenuItem>
    </Items>
    <WebServiceSettings>
        <ODataSettings InitialContainerName="">
        </ODataSettings>
    </WebServiceSettings>
</telerik:RadMenu>

This worked fine before the upgrade, but after we upgraded to the newest version, I started getting the following error in the Chrome developer console on the page that contained the control:

Uncaught TypeError: Cannot read property 'Name' of undefined
b.ODataBinderTree._buildNodeScriptResource.axd:27
b.ODataBinderTree._buildTreeScriptResource.axd:23
b.ODataBinderTreeScriptResource.axd:17
b.NavigationControlODataSettingsScriptResource.axd:7
a.RadMenu.set_webServiceSettingsScriptResource.axd:425
Sys$Component$_setPropertiesScriptResource.axd:3758
Sys$Component$createScriptResource.axd:3816
(anonymous function)http://[websitename]/:856
(anonymous function)ScriptResource.axd:3484
Sys$_Application$_raiseInitScriptResource.axd:5078
Sys$_Application$initializeScriptResource.axd:4928
initScriptResource.axd:5032
Sys$_Application$_domReady.document.addEventListener.check

The RadMenu still displayed, but the dropdown wouldn't work, and other RadControls that appeared later on the page didn't work, probably because the browser simply stopped loading scripts at that point. The fix was to comment out the <WebServiceSettings> tag, which made the error disappear and the functionality return to normal. Since it was a static menu anyway, the functioning of the menu wasn't affected. I figured I'd post this here to help others who might have the same problem, and it might also be something the developers would want to patch in a future version of the controls.

1 Answer, 1 is accepted

Sort by
0
Accepted
Genady Sergeev
Telerik team
answered on 13 Feb 2012, 06:57 AM
Hello Dan Jones,

This is a known bug in the Q3 SP1 release of the RadControls. Please take a look at this forum post for details on how to resolve the problem.

Greetings,
Genady Sergeev
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
Menu
Asked by
Dan
Top achievements
Rank 2
Answers by
Genady Sergeev
Telerik team
Share this question
or