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

Making a column / cell read only conditionally

1 Answer 24 Views
VirtualGrid
This is a migrated thread and some comments may be shown as answers.
Dineesh
Top achievements
Rank 1
Dineesh asked on 14 Nov 2018, 01:06 PM

Hi,

How to make a column or cell read only based on some conditions.

I was exploring the CellFormatting event but cannot find how to achieve that.

1 Answer, 1 is accepted

Sort by
0
Accepted
Dess | Tech Support Engineer, Principal
Telerik team
answered on 15 Nov 2018, 09:33 AM
Hello, Dineesh, 

In order to control the editing process and whether RadVirtualGrid should enter edit mode or no, you can handle the EditorRequired event and set VirtualGridEditorRequiredEventArgs.Editor property to null. Thus, the editor won't be activated. Otherwise, you can leave the default editor. In the event args you have access to the column/row index so you can determine whether to start editing or not.

private void radVirtualGrid1_EditorRequired(object sender, Telerik.WinControls.UI.VirtualGridEditorRequiredEventArgs e)
{
     e.Editor = null;
}

Note that most of the forum threads are reviewed by Telerik representatives and sometimes we address the questions asked by our customers in the forums as well. However, a post in the forum doesn't guarantee you a response from the Telerik support team. Moreover, threads are handled according to license and time of posting, so if it is an urgent problem, we suggest you use a support ticket, which would be handled before a forum thread

I hope this information helps.

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
VirtualGrid
Asked by
Dineesh
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or