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

How to RadControls at ClientSide in OnRowDataBound event?

3 Answers 55 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Somnath
Top achievements
Rank 1
Somnath asked on 16 Jul 2012, 10:13 AM
Hi ,

I am having RadGrid for which I am binding data on clientside in pageLoad() using pageMethods .
In OnRowDataBound() I am able to get particular column using 

args.get_item().get_cell('UniqueColumnName')

Now my requirement is I want to add RadControl ClientSide

Please suggest for the same.

Thanks & Regards,
Somnath 


3 Answers, 1 is accepted

Sort by
0
Accepted
Shinu
Top achievements
Rank 2
answered on 16 Jul 2012, 11:19 AM
Hello,

As far as I know these controls cannot be created from Clientside. Check the following forum thread which discusses the similar scenario.
Create Radcontrols in Client side

Thanks,
Shinu.
0
Somnath
Top achievements
Rank 1
answered on 18 Jul 2012, 07:19 AM
Hi,

Thanks for the quick reply.

Is it possible to create new control by getting the Client Object refrence of already rendered combobox control ?

I tried by following way.
 var vrDimension= $telerik.findControl(insertItem, "ddlDimension");
 RowItem.get_cell('ConstraintName').innerHTML = vrDimension.get_element().cloneNode(true).outerHTML;

Control is getting added this way ,but dropdown is not getting opened with its items.

Please suggest for the same.

Thanks & Regards,
Somnath 
0
Antonio Stoilkov
Telerik team
answered on 23 Jul 2012, 06:39 AM
Hello Somnath,

The desired functionality could be implemented but additional postback is required to dynamically create a RadComboBox control. Another possible solution is to create RadComboBox with Display set to None and then client-side just show the control. Note that cloning a RadComboBox HTML content to create another instance of it is not supported because there is client-side object associated with each control which depends on properties sends from the server which prevents the creation of them purely on the client.

Regards,
Antonio Stoilkov
the Telerik team
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 their blog feed now.
Tags
General Discussions
Asked by
Somnath
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Somnath
Top achievements
Rank 1
Antonio Stoilkov
Telerik team
Share this question
or