954,515 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Datagrid

Get Specific data from datagrid.
i mean when i select row on datagrid, program will return value in that row.

Any Help will appreciated. thx

november_pooh
Junior Poster
121 posts since Mar 2008
Reputation Points: 29
Solved Threads: 0
 

Oh...
i use Vb.net 2003 n MsAccess

november_pooh
Junior Poster
121 posts since Mar 2008
Reputation Points: 29
Solved Threads: 0
 

you mean get data on each row?

Jx_Man
Nearly a Senior Poster
3,329 posts since Nov 2007
Reputation Points: 1,372
Solved Threads: 444
 

Well, try this code :
add this code in datagrid click event.

Dim i As Integer
i = dgAuthor.CurrentRowIndex()
MsgBox(Trim(dgAuthor.Item(i, 0)) & " - " & Trim(dgAuthor.Item(i, 1)) & " - " & Trim(dgAuthor.Item(i, 2)))


Modified as u needed.

Jx_Man
Nearly a Senior Poster
3,329 posts since Nov 2007
Reputation Points: 1,372
Solved Threads: 444
 

yes. that what i needed.
Thank you.

november_pooh
Junior Poster
121 posts since Mar 2008
Reputation Points: 29
Solved Threads: 0
 

you're welcome :)

Jx_Man
Nearly a Senior Poster
3,329 posts since Nov 2007
Reputation Points: 1,372
Solved Threads: 444
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You