Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

is there a grid control (no data) that allows editing?

Status
Not open for further replies.

carlosweiss

Programmer
Sep 15, 2005
15
0
0
AR
Hi,

Is there a grid control that allows to edit the cells in the grid? Datagrid binds the grid to a data source and I don't want it, I just want to put arbitrary data into it, and then read from it. MSFlexGrid or the Microsoft Grid control (from grid32.ocx) don't allow to edit the cells.

I think I could create dinamically a TextBox control on a click event just above the cell that has been clicked but that seems too farfetched. I just want to edit the cells, as though it was a basic spreadsheet.

Thanks!
 
I think I could create dinamically a TextBox control on a click event just above the cell that has been clicked but that seems too farfetched.

That's pretty much what people do.

I just want to edit the cells, as though it was a basic spreadsheet.

And that's pretty much how spreadsheets do it too.


I suppose one could always take a grid control and a textbox control, then wrap them together in a UserControl that does this "magically." Probably even a few out there already.
 
The standard method from MS is illustrated in faq222-3262. You can use it to edit MSFlexgrids using textboxes, comboboxes or even datepickers

________________________________________________________________
If you want to get the best response to a question, please check out FAQ222-2244 first.
'If we're supposed to work in Hex, why have we only got A fingers?'
Drive a Steam Roller
 
Thanks, everybody. Johnwm, that's exactly what I wanted. FAQ222-3262 was very useful.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top