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

Adding templates Client-Side?

1 Answer 48 Views
Menu
This is a migrated thread and some comments may be shown as answers.
David Kemp
Top achievements
Rank 1
David Kemp asked on 28 Apr 2010, 04:13 PM
I am curious to know if I can add template data via the Client-Side api much like the way you can do this server-side. Such as the way you do it in example: http://demos.telerik.com/aspnet-ajax/menu/examples/functionality/templates/defaultcs.aspx I have been able to achieve this server-side by adding this to a root item:

 

Dim ChildItem As Telerik.Web.UI.RadMenuItem = New Telerik.Web.UI.RadMenuItem("MyControl")

 

ChildItem.Controls.Add(MyUserControl)

(The user control has the html)

I've gotten close to the functionality. I've added this code to a root item:

 

 

var item = new Telerik.Web.UI.RadMenuItem();

 

item.set_text('<div style="width: 100px; height: 150px">My template data</div>');

This actually works but it appears to have the menu item functionality overlaid.

Thanks!

1 Answer, 1 is accepted

Sort by
0
Yana
Telerik team
answered on 29 Apr 2010, 11:55 AM
Hi David Kemp,

I'm afraid that templates cannot be added on the client.

All the best,
Yana
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
Tags
Menu
Asked by
David Kemp
Top achievements
Rank 1
Answers by
Yana
Telerik team
Share this question
or