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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data Entry & Form Control

Status
Not open for further replies.

pwomack

Technical User
Apr 16, 2005
121
US
I need to create an unbound data entry form for user input. The data would appear in grid format. I then need to read or reference the data in the grid line-by-line after the user completes data entry.

The data would look like this:
Seq Qty Width Length
1 5 16 8 3/4
2 1 42 19
3 2 48 29 1/4
4 4 10 1/6 31
5 3 27 49
6 13 18 3/8 9 1/2

Can someone suggest which control to use and a method to read the values in the grid line-by-line?

Thanks.
 
If you are using Visual Studio 2005 or later, use a DataGridView. You can directly add new rows and columns. If 2002 or 2003, you can use a DataGrid bound to a DataTable which you create in memory--meaning DataBound. You can then loop through the DataTable.

Another option to consider if you're not going to have more than maybe a couple dozen records would be to use control arrays.

It's important to remember that being DataBound in .Net doesn't have anything to do with a database and a cursor. It's bound to objects in memory. Sometimes those objects have links back and forth to a database, sometimes not.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top