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

DataNavigateUrlField target

7 Answers 101 Views
PanelBar
This is a migrated thread and some comments may be shown as answers.
Kjell
Top achievements
Rank 1
Iron
Kjell asked on 12 Dec 2012, 11:36 PM
How set DataNavigateUrlField target?
I load telerik:RadMenu from SqlDataSource and want to bind target field....

7 Answers, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 13 Dec 2012, 05:33 AM
Hi Kjell,

I suppose you want to use a databinding to specify the Target for all menu items. Try the following code snippet.

ASPX:
<telerik:RadMenu runat="server" ID="RadMenu1">
    <DataBindings>
        <telerik:RadMenuItemBinding Target="myTarget" />
    </DataBindings>
</telerik:RadMenu>

If the the name of the window is stored in the database you can use the following databinding.

ASPX:
<telerik:RadMenu runat="server" ID="RadMenu1">
    <DataBindings>
        <telerik:RadMenuItemBinding TargetField="WindowName" />
    </DataBindings>
</telerik:RadMenu>

Hope this helps.

Regards,
Princy.
0
Kjell
Top achievements
Rank 1
Iron
answered on 19 Jun 2013, 07:48 AM
Target Field will not work anymore, it's changed in the latest version?
0
Helen
Telerik team
answered on 20 Jun 2013, 11:44 AM
Hi Kjell,

What is the exact version of the Telerik.Web.UI.dll that you use?
We tested the behavior with the latest version (2013.2.611.40) and it works.

Here is a sample code:
<telerik:RadMenu
    runat="server"
    ID="RadMenu1"
    DataSourceID="XmlDataSource1"
    DataFieldID="id"
    DataFieldParentID="parentID" >
    <DataBindings>
        <telerik:RadMenuItemBinding Depth="0" TextField="Text" CssClass="rootItems" Target="_blank" NavigateUrlField="NavigateUrl"/>
        <telerik:RadMenuItemBinding Depth="1" ImageUrlField="ImageUrl" TextField="Text" />
    </DataBindings>
</telerik:RadMenu>
 
<asp:XmlDataSource runat="server" ID="XmlDataSource1" DataFile="Menu.xml" XPath="/Menu/MenuItem">
</asp:XmlDataSource>



Regards,
Helen
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Kjell
Top achievements
Rank 1
Iron
answered on 20 Jun 2013, 12:18 PM
Target works for the root menu, not in  the sub menu......
I have try Target="_blank"
I use latest version (2013.2.611.45)


<telerik:RadPanelBar ID="rpbOmOss" runat="server"
    CookieName="CookieOmOss"
    DataSourceID="SqlOmOssPanel"
    DataFieldID="NodeId"
    DataFieldParentID="ParentNodeId"
    DataTextField="sidnamn"
    DataNavigateUrlField="NavigateUrl"
    EnableEmbeddedSkins="False"
    ExpandMode="SingleExpandedItem"
    OnItemDataBound="RadPanelBar1_ItemDataBound"
    PersistStateInCookie="True"
    Skin="NewTransparent"
    Width="100%" Height="380px">
    <DataBindings>
        <telerik:RadPanelItemBinding TargetField="target" Depth="0" Expanded="True" />
    </DataBindings>
</telerik:RadPanelBar>
0
Helen
Telerik team
answered on 20 Jun 2013, 01:17 PM
Hi Kjell,

Please change the DataBindings setting to affect the second level as well:

<DataBindings>
       <telerik:RadPanelItemBinding TargetField="target" Depth="0" Expanded="True" />
       <telerik:RadPanelItemBinding TargetField="target" Depth="1" Expanded="True" />
</DataBindings>

You have a setting only for root level.

Regards,
Helen
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Kjell
Top achievements
Rank 1
Iron
answered on 18 Jan 2016, 08:13 AM

And now the TargetField have stop work again. What to do?

I have:

    <DataBindings>
        <telerik:RadPanelItemBinding TargetField="target" Depth="0" Expanded="False" />
        <telerik:RadPanelItemBinding TargetField="target" Depth="1" Expanded="True" />
    </DataBindings>

0
Helen
Telerik team
answered on 19 Jan 2016, 07:53 AM
Hello Kjell,

What is the exact version of the Telerik.Web.UI that you use?
Could you open a support ticket and send us your complete code to examine it locally?


Regards,
Helen
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
PanelBar
Asked by
Kjell
Top achievements
Rank 1
Iron
Answers by
Princy
Top achievements
Rank 2
Kjell
Top achievements
Rank 1
Iron
Helen
Telerik team
Share this question
or