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

Find TextBox in RadComboBox.

3 Answers 125 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Abhijit Shetty
Top achievements
Rank 2
Abhijit Shetty asked on 13 Mar 2013, 04:04 AM
Hi,
I need to set few attributes to TextBox of RadComBox.
Same can be done using javascript as:
var txtCurrency = $find(rcbCurrencyId).get_inputDomElement();
txtCurrency.setAttribute('test', 'test');
Need to do same via Server - Side.

3 Answers, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 13 Mar 2013, 05:04 AM
Hi Abhijit,

As far as I know, it is not possible to get the reference of input element from server-side code. Normally client side code is used to accomplish such requirements. If it is an item template you can use the FindControl() to access them from server-side.

Thanks,
Princy.
0
Abhijit Shetty
Top achievements
Rank 2
answered on 14 Mar 2013, 08:43 AM
Hi Princy,
Thanks for your quick reply.
I was just wondering how difficult it would be for Telerik developers to replica same functionality in server-side that is implemented in client-side. It will help developer a lot.
0
Peter Filipov
Telerik team
answered on 15 Mar 2013, 11:30 AM
Hi Abhijit,

The RadControl support attributes collection at the server side - Attributes. They are rendered at the control's element. E.g.:
RadComboBox1.Attributes.Add("myCustomAttribute", "myValue")

All the best,
Peter Filipov
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
ComboBox
Asked by
Abhijit Shetty
Top achievements
Rank 2
Answers by
Princy
Top achievements
Rank 2
Abhijit Shetty
Top achievements
Rank 2
Peter Filipov
Telerik team
Share this question
or