Render RadDropdownlist from C# code behind

3 posts, 0 answers
  1. Kalpesh
    Kalpesh avatar
    8 posts
    Member since:
    Nov 2013

    Posted 21 Nov 2013 Link to this post

    Hello

    Current Scenario: Currently we are generating html select (dropdown) from code behind using string builder and adding the generated HTML into literal control - which will display the HTML. Below is the code snippet.

    html.Append("<select name=test id=test class='xyz' onchange=\"changeDD(this);\" >");
    html.Append("<option value='1'>xyz</option>");

    We have number of controls being rendered dynamically based on customer settings. Now, We are trying to replace this html select (dropdown) with Telerik RadDropdownlist.

    Please suggest the approach or provide your inputs to achieve this kind of HTML rendering from code behind. Also we have JS written for some of the controls.

    Please let me know if you need more details.
  2. Nencho
    Admin
    Nencho avatar
    1457 posts

    Posted 26 Nov 2013 Link to this post

    Hello Kalpesh,

    Thank you for contacting Telerik Support.

    I had prepared a sample page for you, demonstrating how to create grammatically the RadDropDownList at code-behind and assign the client-side events. Please find it attached and let me know if any further assistance is needed.

    Hope this would help. I will be glad to assist you any further.

    Regards,
    Nencho
    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.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Kalpesh
    Kalpesh avatar
    8 posts
    Member since:
    Nov 2013

    Posted 26 Nov 2013 Link to this post

    Hello,

    Thanks for the sample.
Back to Top