Hi Saurabh,
In the Web page, the mouseover event is a client event, so you won't find it
in C# server-side events. However, you can add the JavaScript code in
ASP.NET.
See the code sample below that demonstrates the technique.
Let us know if this helps?
Ken
Microsoft MVP [ASP.NET]
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">
protected void Page_Load
(object sender, EventArgs e)
{
ImageButton1.Attributes.Add("onmouseover",
"this.src='http://www.gc.ca/images/francaisbt.gif'");
ImageButton1.Attributes.Add("onmouseout",
"this.src='http://www.gc.ca/images/englishbt.gif'");
}
</script>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>MouseOver MouseOut Image</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:imagebutton id="ImageButton1" runat="server"
imageurl="http://www.gc.ca/images/englishbt.gif" /></div>
</form>
</body>
</html>
"Saurabh" <(E-Mail Removed)> wrote in message
news:678DCE81-E109-408C-BA72-(E-Mail Removed)...
> I'm a user of Visual Studio Web Developer 2005 Express Edition & I use C#
> as
> the language in it. So, the problem i'm facing is that I want to add a
> MouseHover event to an image but i could'nt find it in the Events' list in
> Properties window as in Microsoft Visual C# 2005 Express Edition.Can you
> tell
> me where it lies or isthere any other way to do it in Web Developer. I'll
> be
> thankful if you solve my problem.
>
> Saurabh
>
>
|