How can I get a RadTextbox object with javascript?

3 posts, 0 answers
  1. winson qiu
    winson qiu avatar
    2 posts
    Member since:
    Jul 2009

    Posted 28 Jul 2009 Link to this post

    I have tried to use
    var inputElement = $get('<%=RadInput1.ClientID%>' + '_text');

    or

    var dateInput = $find("<%= RadDateInput1.ClientID %>");


    to get the radtextbox object ,but it's not worked. my javascript script must be put in a page head , then how can I get the object ?

    thanks!
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 28 Jul 2009 Link to this post

    Hello Winson,

    You would have to pass the Id of the RadtextBox as shown below to get the RadTextBox client side object:
    aspx:
    <telerik:RadTextBox ID="RadTextBox1" runat="server"
    </telerik:RadTextBox> 

    js:
    var textbox = $find("<%= RadTextBox1.ClientID %>"

    Thanks
    Princy.
  3. winson qiu
    winson qiu avatar
    2 posts
    Member since:
    Jul 2009

    Posted 28 Jul 2009 Link to this post

    maybe I use in a usercontrol , so I cannot get the object wiht the statement, any ideas ?

    thanks!
Back to Top