Adding simple label to Advanced form

4 posts, 0 answers
  1. Sander
    Sander avatar
    13 posts
    Member since:
    Aug 2011

    Posted 19 Aug 2011 Link to this post

    Hi there,

    I have a question, do someone know if it's possible to add a simple label to the advanced form without using a custom template or something like that?I want to add the label via my C# code.


  2. Ivana
    Ivana avatar
    657 posts

    Posted 22 Aug 2011 Link to this post

    Hello Sander,

    You can find instructions of how to access the controls in the advanced form here.

    One solution is to attach a handler on the OnFormCreated event and check if the Scheduler is in insert or edit mode. If that is so, find some control (depending on where you want to put the label) from the form, find its parent and add your label as a child of the parent control. 

    Example: subjectTextbox.Parent.Controls.Add(testLabel);
    *subjectTextbox - control from the advanced form.
    *testLabel - label I want to put in the form.

    Best wishes,
    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

  3. Ron
    Ron avatar
    5 posts
    Member since:
    Feb 2012

    Posted 11 Jan 2013 Link to this post

    Do you have any examples on how to do this?
  4. Plamen
    Plamen avatar
    3080 posts

    Posted 14 Jan 2013 Link to this post

    Hi John,

    You can refer to the Handling FormCreated help topic where is provided the exact coed use to add a control in the Add a new combobox that updates the subject field section.

    Please let me know if you have further questions concerning this issue.

    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.
Back to Top