|
-
May 10th, 2004, 11:49 PM
#1
Thread Starter
Addicted Member
Datagrid - Deleting Rows
Does any body know how to prevent a user from deleting rows from a datagrid?
-
May 11th, 2004, 04:33 AM
#2
Fanatic Member
set the 'ReadOnly' property to True.
but this will also restrict the user to add any new records.
-
May 11th, 2004, 03:42 PM
#3
Thread Starter
Addicted Member
i know about the readonly property.
i want a situation whereby if rows are selected, and delete button on the keyboard pressed, the rows will not be deleted.
-
May 14th, 2004, 02:08 AM
#4
Fanatic Member
Then, on the KeyDown event of ur grid, check if the row is selected and if Del. key is pressed. If so, then set the e.Cancel to True.
Hope it helps
-
Aug 29th, 2004, 10:23 PM
#5
or make a datagridtablestyle and set the textbox.enable = false..
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|