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

change Prometheus menuitem navigate url

3 Answers 80 Views
Menu
This is a migrated thread and some comments may be shown as answers.
lakshmi
Top achievements
Rank 1
lakshmi asked on 15 Apr 2008, 08:08 PM
Is possible change the Prometheus menuitem navigate url from client side with javascript?

3 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 16 Apr 2008, 08:46 AM
Hi Lakshmi,

Yes, by design you can change the NavigateUrl value with the set_navigateUrl("myUrl") method. Here is a small example:

<script type="text/javascript">  
function TweakMenuItem()  
{  
    var menu = $find("RadMenu1");  
    var menuItem = menu.get_allItems()[0];              
    menuItem.set_text("Telerik");  
    menuItem.set_navigateUrl("http://www.telerik.com");   
}  
</script> 
<telerik:RadMenu ID="RadMenu1" runat="server" Flow="Horizontal">  
    <DefaultGroupSettings ExpandDirection="Auto" Flow="Vertical" /> 
    <CollapseAnimation Duration="200" Type="OutQuint" /> 
    <Items> 
        <telerik:RadMenuItem runat="server" ExpandMode="ClientSide" NavigateUrl="http://www.yahoo.com" Text="yahoo">  
            <GroupSettings ExpandDirection="Auto" Flow="Vertical" /> 
        </telerik:RadMenuItem> 
        <telerik:RadMenuItem runat="server" ExpandMode="ClientSide" NavigateUrl="http://www.google.com" Text="google">  
            <GroupSettings ExpandDirection="Auto" Flow="Vertical" /> 
        </telerik:RadMenuItem> 
    </Items> 
    <ExpandAnimation Type="OutQuart" /> 
</telerik:RadMenu> 
<input id="Button1" onclick="TweakMenuItem()" type="button" value="button" /> 

However, we discovered that the set_navigateUrl() method doesn't work as expected with the current version of Telerik.Web.UI. However, with the Q1 2008 release today, this bug should be fixed.


Greetings,
Peter
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Ioanna Ioannidou
Top achievements
Rank 1
answered on 27 Aug 2008, 02:58 PM
Rather ... does not work at all you mean ....
Any chance of a fix with the Q2 version ?
0
Peter
Telerik team
answered on 01 Sep 2008, 06:53 AM
Hi Ioanna,

I am glad to inform you that the bug has already been fixed. Have you tried with the latest version? Please, feel free to let us know if you experience any problems.


Kind regards,
Peter
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Menu
Asked by
lakshmi
Top achievements
Rank 1
Answers by
Peter
Telerik team
Ioanna Ioannidou
Top achievements
Rank 1
Share this question
or