Solved

ImageButton Not Firing In Chrome

Posted on 2013-01-11
5
571 Views
Last Modified: 2013-01-12
ImageButtons (VS2010) work fine in IE but do not call code-behind when using Chrome.
0
Comment
Question by:cehrnow
  • 3
5 Comments
 
LVL 35

Expert Comment

by:Miguel Oz
ID: 38769212
Check:
http://stackoverflow.com/questions/6703822/image-button-click-event-not-firing-in-chrome
You may need to do the css rules suggested in the link.

Note: If it does not work please post your image button markup and the rendered HTML from Chrome.
0
 

Author Comment

by:cehrnow
ID: 38769623
onMouseOver and onMouseOut work okay but onClick does not fire.

<img src="List.gif" id="cmdMenu" style="left:22;width:56;height:26px;position:absolute;top:15px;Visibility:visible;cursor:hand;" width="96" border="0" alt="List" onClick="cmdSelect()" onMouseOver="cmdMouseOver()" onMouseOut="cmdMouseOut()" />
0
 

Author Comment

by:cehrnow
ID: 38769629
<img id="cmdMenu" style="left: 22px; cursor: hand; position: absolute;
top: 15px" height="26" alt="List" src="List.gif" width="56" runat="server" />
0
 
LVL 38

Accepted Solution

by:
Tom Beck earned 500 total points
ID: 38769954
It must have something to do with what you are doing in the mouseover and mouseout events because the click event fires in Chrome in this test.
<img src="List.gif" id="cmdMenu" style="left:22px;width:56px;height:26px;position:absolute;top:15px;visibility:visible;cursor:hand;" border="0" alt="List" onClick="cmdSelect()" onMouseOver="cmdMouseOver(this)" onMouseOut="cmdMouseOut(this)" />
<script type="text/javascript">
function cmdSelect() {
	alert("cmdSelect()");
}
function cmdMouseOver(ele) {
	ele.src = "List_over.gif";
}
function cmdMouseOut(ele) {
	ele.src = "List.gif";
}
</script>

Open in new window

0
 

Author Closing Comment

by:cehrnow
ID: 38769956
You were right...in the event being called itself.
0

Featured Post

Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In .NET 2.0, Microsoft introduced the Web Site.  This was the default way to create a web Project in Visual Studio 2005.  In Visual Studio 2008, the Web Application has been restored as the default web Project in Visual Studio/.NET 3.x The Web Si…
ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question