Error with RadGrid with RadCombo

5 posts, 0 answers
  1. Praveen
    Praveen avatar
    34 posts
    Member since:
    Apr 2009

    Posted 10 Feb 2015 Link to this post

    Getting below error while binding Combo Box on demand in RadGrid with BatchEdit Mode. Please help

     The target 'ctl11$RadGridSearchResult$ctl11_RadGridSearchResult_ctl00_Actplc$Actplc' for the callback could not be found or did not implement ICallbackEventHandler. 

    public class CreateRadComboTemplate : ITemplate
        {
            private string tempName;
            private int catId;
            public CreateRadComboTemplate(string templateName, int catId)
            {
                this.tempName = templateName;
                this.catId = catId;
            }

            public void InstantiateIn(System.Web.UI.Control container)
            {
                RadComboBox rcBox = new RadComboBox();
                rcBox.ID = this.tempName;
                rcBox.ItemsRequested += rcBox_ItemsRequested;
                rcBox.EnableAutomaticLoadOnDemand = true;
                container.Controls.Add(rcBox);
            }

            void rcBox_ItemsRequested(object sender, RadComboBoxItemsRequestedEventArgs e)
            {
                //throw new NotImplementedException();
            }
        }
  2. Angel Petrov
    Admin
    Angel Petrov avatar
    1006 posts

    Posted 13 Feb 2015 Link to this post

    Hello Praveen,

    Without having a better understanding of the exact implementation it would be hard to tell why are you experiencing such behavior. That said please share with us the entire markup and code-behind of the page.

    Additionally have in mind that when batch editing is used the templates should inherit from IBindableTemplate. Please modify the templates definition and let us know if this has helped you resolve the matter.

    Regards,
    Angel Petrov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Praveen
    Praveen avatar
    34 posts
    Member since:
    Apr 2009

    Posted 16 Feb 2015 in reply to Angel Petrov Link to this post

    I am getting lot of issues. Could you please provide me sample code for my scenario as explain below

    I have dynamic search dataset (columns can be change) and that need to bind with grid for batch edit (Cell). Based on column type, I need to bind controls for batch editing. 
    For example, let’s say 
    1. For column type INT, I need to bind textbox for batch edit mode, 
    2. for text (varchar), need to bind dropdown
    3. for text (varchar(max)), need to bind RadEditor

    Thanks
    Praveen Tomar


  5. Angel Petrov
    Admin
    Angel Petrov avatar
    1006 posts

    Posted 19 Feb 2015 Link to this post

    Hello Praveen,

    I am sorry to say but providing fully runnable solutions that target custom scenarios like the described is not supported. That said I would like to ask you to share with us the problematic page contents alongside with a detail description of the problems so we could examine what is causing them.

    As for the functionality itself it looks like you want to dynamically change the editors according to the search results. This can be achieved by following one of the approaches described below.
    1. Dynamically change the templates or columns according to the search result. Have in mind that if templates will be used the search result should be available in the OnInit event as defining templates programmatically on a later stage will cause problems. The sample principle applies if the columns will be dynamically changed with the slight difference that here you can use the page load event. I strongly suggest examining this help article which explains in detail how one can programmatically create the grid structure.
    2. Initialize all the editor types in a template column and manually handle the editing process on the client by subscribing to the four batch editing events(OnBatchEditGetCellValue, OnBatchEditSetCellValue, OnBatchEditGetEditorValue, OnBatchEditSetEditorValue). The idea here is to show only one editor and use it to edit the cell contents. An example of such type of manual handling of the edit process can be found here.


    Regards,
    Angel Petrov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  6. Jaya
    Jaya avatar
    81 posts
    Member since:
    Mar 2011

    Posted 19 Feb 2015 in reply to Angel Petrov Link to this post

    Hi
    Can u solve this issue

    http://www.telerik.com/forums/how-to-find-control-id-telerik-radgrid
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017