This is a migrated thread and some comments may be shown as answers.

Setting Editmode of Radgrid break select element IE

1 Answer 31 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Dave
Top achievements
Rank 1
Dave asked on 08 Jan 2015, 08:24 AM
Hi..

I've tracked a problem down which I initially thought was related to Tabstrip but seems it is actually setting the grid edit mode in code whereby including the lines of code below prevent a select box working in IE 11 on my page. If I comment the lines of code out the select box then works fine. This issue doesn't appear on firefox/chrome though only IE.

                 RadGrid1.MasterTableView.EditMode = GridEditMode.Batch;
                RadGrid1.MasterTableView.BatchEditingSettings.EditType = GridBatchEditingType.Cell;

The procedure simply displays a hidden column and changes the editmode. I'm wondering if the same thing can be done client side? Is there a way in javascript to achieve result?

    if (RadGrid1.MasterTableView.GetColumn("Map").Display != true)
            {
                RadGrid1.MasterTableView.EditMode = GridEditMode.Batch;
                RadGrid1.MasterTableView.BatchEditingSettings.EditType = GridBatchEditingType.Cell;
                RadGrid1.MasterTableView.GetColumn("Map").Display = true;
                foreach (GridColumn col in RadGrid1.MasterTableView.Columns)
                    if (col.UniqueName == "col1" || col.UniqueName == "col2" || col.UniqueName == "col3")
                    {
                        GridBoundColumn boundColumn = col as GridBoundColumn;
                        boundColumn.ReadOnly = true;
                    }                  
             }
               
           else
            {
               RadGrid1.MasterTableView.EditMode = GridEditMode.EditForms;                
               RadGrid1.MasterTableView.GetColumn("Map").Display = false;
               foreach (GridColumn col in RadGrid1.MasterTableView.Columns)
                   if (col.UniqueName == "col1" || col.UniqueName == "col2" || col.UniqueName == "col3")
                   {
                       GridBoundColumn boundColumn = col as GridBoundColumn;
                       boundColumn.ReadOnly = false;
                   }
            }

1 Answer, 1 is accepted

Sort by
0
Angel Petrov
Telerik team
answered on 12 Jan 2015, 11:29 AM
Hi Dave,

Showing/hiding a column on the client is possible however changing the EditMode is not as this action requires the execution of a postback.

As for the described behavior I have to say that it is not expected. However we can not tell for sure what causes it without having e better understanding of the exact implementation. That said please share with us the markup and code-behind of the page so we could further research 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.

 
Tags
Grid
Asked by
Dave
Top achievements
Rank 1
Answers by
Angel Petrov
Telerik team
Share this question
or