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

ReadOnlyChanged Event

1 Answer 73 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Doug
Top achievements
Rank 1
Doug asked on 01 Aug 2013, 08:49 PM
Is there any ReadOnlyChanged event for the GridView?  I don't see one for the GridView control itself.  Maybe it's down some path like ElementTree.  I'm searching but I can't find it.  What I'd like to do is set the ReadOnly property on that custom RadRadioButtonColumn whenever the GridView property changes.

Thank you,
Gary

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 06 Aug 2013, 11:17 AM
Hello Gary,

Thank you for writing.

You can use the PropertyChanged event of the desired template to detect when the read only property value has changed: 
void MasterTemplate_PropertyChanged(object sender, PropertyChangedEventArgs e)
{
    if (e.PropertyName == "GridReadOnly")
    {
        // your code goes here
    }
}

Use the following line of code to wire the event:
radGridView1.MasterTemplate.PropertyChanged += MasterTemplate_PropertyChanged;

Also keep in mind that every column has its own ReadOnly property. If you set this property to true your column will remain read only even if you set the grid's ReadOnly property to false.

I hope this helps. Should you have any other questions do not hesitate to ask.

Regards,
Dimitar
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINFORMS.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
GridView
Asked by
Doug
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Share this question
or