|
-
Dec 12th, 2008, 09:17 AM
#1
Thread Starter
Hyperactive Member
[RESOLVED] Datagrid problem
Hi I have a dategrid on my form and I can't edit any cell in the datagrid could any one help me out.
thanks
-
Dec 16th, 2008, 06:12 AM
#2
Frenzied Member
Re: Datagrid problem
Is it a bound grid?
How is it populated?
-
Dec 17th, 2008, 06:13 AM
#3
Thread Starter
Hyperactive Member
Re: Datagrid problem
 Originally Posted by petevick
Is it a bound grid?
How is it populated?
Yes it is bond to a dataset and it is populated upon selecting somethngfrom a combobox which selectedvalue is the value to the command value.
-
Dec 17th, 2008, 10:27 AM
#4
Frenzied Member
Re: Datagrid problem
http://msdn.microsoft.com/en-us/library/ms180748.aspx should help for VS2008, or for VS2005 you can provide a invisble control for data entry (TextBox, ComboBox, etc) and then handle the "DoubleClick" event for the DataGrid. In that handler, use the DataGrid.CurrentCell to determine your current cell. Then, set the bounds of your TextBox (or other control) to DataGrid.GetCellBounds. Finally, you can copy the contents of the cell to your TextBox, Select it, make it visible, and edit away - does that help?
-
Dec 17th, 2008, 06:10 PM
#5
Thread Starter
Hyperactive Member
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
|