Find Control In Insert Item Grid Client Side

4 posts, 0 answers
  1. Rasool
    Rasool avatar
    15 posts
    Member since:
    Mar 2015

    Posted 30 Mar 2015 Link to this post

    Hi dear

    How we can find controls(Radcombobox) in insert item of radgrid on client side.

    Thanks
  2. Eyup
    Admin
    Eyup avatar
    3005 posts

    Posted 02 Apr 2015 Link to this post

    Hello Rasool,

    Generally, you can use the OnClientLoad event handler of the combo to achieve this requirement. Alternatively, you can use the $telerik.findControl and $telerik.findElement methods to access any controls on the client. I am attaching a sample RadGrid web site to demonstrate a more advanced scenario.

    Hope this helps.

    Regards,
    Eyup
    Telerik
     

    See What's Next in App Development. Register for TelerikNEXT.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Rasool
    Rasool avatar
    15 posts
    Member since:
    Mar 2015

    Posted 08 Apr 2015 in reply to Eyup Link to this post

    Hi Eyup

    I use the code :

    function rcb_kala_OnClientSelectedIndexChanged(sender, args) {
                       
                        var grid = $find('<%=rg_anbarSanadSub.ClientID%>');
                        var insertItemForm = grid.get_masterTableView().get_insertItem();
                        if (insertItemForm) {
                            var rtxt_NameKala = $telerik.findControl(editForm, "rtxt_NameKala");
                            rtxt_NameKala.set_value("1");
                        }
                    }

     

    but get_insertItem() return always null.Why?

     

    Please help me

    Thanks

     

  5. Eyup
    Admin
    Eyup avatar
    3005 posts

    Posted 13 Apr 2015 Link to this post

    Hello Rasool,

    Could you share which edit mode do you use and verify that the Insert form is open at the moment when the script runs?
    <MasterTableView ... EditMode="EditForms">

    Regards,
    Eyup
    Telerik
     

    See What's Next in App Development. Register for TelerikNEXT.

     
Back to Top