Last post Dec 04, 2008 11:45 AM by JAYHAWKER
Dec 04, 2008 08:58 AM|JAYHAWKER|LINK
I have a subroutine and am wanting to use multiple handles to run it, altering the code in the subroutine based on a number in the handles name. For example, I have 8 thumbnails and when they are clicked, I change the image url of an enlarged image to the
imageurl of the thumbnail. My thumbnails are named thumbnail1, thumbnail2, etc. My subroutine looks like this.
Sub ThumbNail_Click(ByVal sender
Handles ThumbNail1.Click, ThumbNail2.Click
ImageLargeStatic.ImageUrl = Thumbnail?.ImageUrl
I want to determine which handle was used and then pull the number (1 or 2 in this case) out
to be able to put it in the ? of the code above.
Dec 04, 2008 09:39 AM|jgangwisch|LINK
try converting your code to this:
ImageLargeStatic.ImageUrl = Sender.ImageUrl
Dec 04, 2008 11:45 AM|JAYHAWKER|LINK