|
-
Feb 2nd, 2005, 10:06 AM
#1
Thread Starter
Fanatic Member
[Resolved] Get ID from Data grid when user clicks on hyperlink button
I have a datagrid that has several columns and several records. The last column (column7) has the ID of the record. When the user clicks the hyperlink button, I want to put the ID of the record into a session variable for use in the next web page.
Anyone have any ideas?
Thanks
Last edited by indydavid32; Feb 2nd, 2005 at 03:56 PM.
David Wilhelm
-
Feb 2nd, 2005, 11:30 AM
#2
Frenzied Member
Re: Get ID from Data grid when user clicks on hyperlink button
Is it a hyperlink button managed by the DataGrid or one of your own?
Magiaus
If I helped give me some points.
-
Feb 2nd, 2005, 03:06 PM
#3
Thread Starter
Fanatic Member
Re: Get ID from Data grid when user clicks on hyperlink button
It is a hyperlink that is a part of the datagrid.
-
Feb 2nd, 2005, 03:12 PM
#4
Frenzied Member
Re: Get ID from Data grid when user clicks on hyperlink button
Do you have a Command Name set for it? If you do you can use Command event and the event args.
e.Item.Cells(7).Text = your key
Magiaus
If I helped give me some points.
-
Feb 2nd, 2005, 03:22 PM
#5
Thread Starter
Fanatic Member
Re: Get ID from Data grid when user clicks on hyperlink button
What sub would I use where that code would run when they click on the hyperlink? I tried DataGrid1_SelectedIndexChanged and it didn't run.
-
Feb 2nd, 2005, 03:23 PM
#6
Frenzied Member
Re: Get ID from Data grid when user clicks on hyperlink button
Magiaus
If I helped give me some points.
-
Feb 2nd, 2005, 03:53 PM
#7
Thread Starter
Fanatic Member
Re: Get ID from Data grid when user clicks on hyperlink button
I put some code there and a stopper and it did not run when I clicked the hyperlink button.
-
Feb 2nd, 2005, 03:56 PM
#8
Thread Starter
Fanatic Member
Re: Get ID from Data grid when user clicks on hyperlink button
I got it. I used Select and then put the code in SelectedIndexChanged and it worked great.
Thanks for you help.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|