943,896 Members | Top Members by Rank

Ad:
  • VB.NET Discussion Thread
  • Marked Solved
  • Views: 711
  • VB.NET RSS
Jun 9th, 2008
0

Datagrid

Expand Post »
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
Similar Threads
Reputation Points: 29
Solved Threads: 0
Junior Poster
november_pooh is offline Offline
120 posts
since Mar 2008
Jun 9th, 2008
0

Re: Datagrid

Oh...
i use Vb.net 2003 n MsAccess
Reputation Points: 29
Solved Threads: 0
Junior Poster
november_pooh is offline Offline
120 posts
since Mar 2008
Jun 9th, 2008
1

Re: Datagrid

you mean get data on each row?
Reputation Points: 1182
Solved Threads: 392
Posting Sensei
Jx_Man is offline Offline
3,140 posts
since Nov 2007
Jun 9th, 2008
4

Re: Datagrid

Well, try this code :
add this code in datagrid click event.
vb.net Syntax (Toggle Plain Text)
  1. Dim i As Integer
  2. i = dgAuthor.CurrentRowIndex()
  3. MsgBox(Trim(dgAuthor.Item(i, 0)) & " - " & Trim(dgAuthor.Item(i, 1)) & " - " & Trim(dgAuthor.Item(i, 2)))

Modified as u needed.
Last edited by Jx_Man; Jun 9th, 2008 at 2:30 am.
Reputation Points: 1182
Solved Threads: 392
Posting Sensei
Jx_Man is offline Offline
3,140 posts
since Nov 2007
Jun 9th, 2008
0

Re: Datagrid

yes. that what i needed.
Thank you.
Reputation Points: 29
Solved Threads: 0
Junior Poster
november_pooh is offline Offline
120 posts
since Mar 2008
Jun 9th, 2008
0

Re: Datagrid

you're welcome
Reputation Points: 1182
Solved Threads: 392
Posting Sensei
Jx_Man is offline Offline
3,140 posts
since Nov 2007

This thread is solved

Either the thread starter or a moderator has marked this thread as solved. You can most likely trust the responses and answers given. There is most likely no reason for any further responses to be posted here. If you have a related question, please start a new thread in this forum instead.

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in VB.NET Forum Timeline: How do I replace Enter
Next Thread in VB.NET Forum Timeline: Code to compare two files and display their difference.





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC