Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to close form with esc key in Datagrid
Message
From
22/11/2006 13:55:09
 
 
To
21/11/2006 00:45:08
General information
Forum:
ASP.NET
Category:
Forms
Environment versions
Environment:
C# 1.1
Miscellaneous
Thread ID:
01171053
Message ID:
01171880
Views:
12
>Hi Andrus,
>
>Basically, you have to override the ProcessCmdKey method in your DataGrid sub-class ... see this article for more information:
>
>http://www.codeproject.com/cs/database/DatabaseAcessWithAdoNet1.asp#Keystrokes

Thank you. It works.
But how to close form from DataGrid ProcessCmdKey() method?

I used
((Form)this.Parent.Parent.Parent) .Close();
If grid is not placed in tabpage then this code does not work.
How to find grid parent form ?
In Visual FoxPro this is easy becauses VFP has thisform

However, DataGrid does not have parentform property.
Andrus
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform