We help IT Professionals succeed at work.

ASP.net Enlarge Grid View ImageButton on MouseOver

cmerlo1
cmerlo1 asked
on
1,286 Views
Last Modified: 2008-01-09
I have a datagrid that contains a template field with the following image button:

<asp:ImageButton ID="ImageButton6" runat="server" CommandName="Select" ImageUrl='<%# Eval("PicURL1") %>' ImageAlign="AbsMiddle" BorderColor="Black" BorderStyle="Double" BorderWidth="3px" Width="50px" />

I would like a simple way to double the image size when a user moves the mouse pointer over the image button.  I have tried adding: onmouseover="this.width=100;" but this does not work (I didn't think it would be that simple) and VWD 2008 tells me that mouseover isn't an attribute of the image.  I try adding the attribute via VBScript on the pageload event, but the ImageButton6 ID isn't recognized and the page errors out...is there a simple javascript or vbscript code snippet that will accomplish this?
Comment
Watch Question

Systems architect
CERTIFIED EXPERT
Top Expert 2006
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
Perfect!
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.