Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > .NET General

Vista - DataGrid Question

Reply
 
Old 10-09-2008   #1 (permalink)
fripper


 
 

DataGrid Question

I am using VB .Net 2003.

I am really struggling to understand how to display a table (datagrid) in a
web app. Let me explain what I want to do ... I want the table to be, say,
six columns wide. Columns 1, 3, 5 and 6 will contain data that is in an
array ... assume it is simple integer data. Now, I want columns 2 and 4 to
be pushbutton columns whereby when the user clicks on either the pushbutton
in column 2 or the one in column 4 an event is fired (SelectedIndexChanged)
that allows me to determine the row number AND the column number of the
button that was clicked. I have played around with this some using a
datagrid. At design time I can seet up the two puchbutton columns (using
the columns property of the datagrid) but I don't know how to make them
appear in columns 2 and 4 ... it seems that they come first and then the
data columns I add programmatically. So I have two questions:

How do I get the pushbuttons into columns 2 and 4?
How do I determine which column a pushbutton is in when a user clicks it?


Thanks for any help ... this problem is driving me batty!





My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
DataGrid Question .NET General
Verb Counts - WPF DataGrid PowerShell
Simple Datagrid question .NET General


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46