473,387 Members | 1,791 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Imagebutton click

Hi,
I am using imagebutton menu on webpage for navigation.
Code adds OnClick attribute and when one clicks on it, redirects him to that
page. and the same menu appears. This time I want to disable click so it is
just a button without link.
How can I remove link so that it is not clickable when on that page?

Thank you in advance.

Shailesh
Sep 28 '07 #1
2 1397
ImageButtons have a property called Enabled. The Boolean False will "disable"
the button and you won't be able to click on it. Another useful tactic is
to style it as well to "gray" it out.

Style="filter: alpha(opacity=25);" provides a neat little washout of most
images when disabling them.

HTH.

-dl
--
David R. Longnecker
http://blog.tiredstudent.com
Hi,
I am using imagebutton menu on webpage for navigation.
Code adds OnClick attribute and when one clicks on it, redirects him
to that
page. and the same menu appears. This time I want to disable click so
it is
just a button without link.
How can I remove link so that it is not clickable when on that page?
Thank you in advance.

Shailesh

Sep 28 '07 #2
Great!
Worked.

Thank you.

Shailesh

"David R. Longnecker" <dl*********@community.nospamwrote in message
news:46*************************@msnews.microsoft. com...
ImageButtons have a property called Enabled. The Boolean False will
"disable" the button and you won't be able to click on it. Another useful
tactic is to style it as well to "gray" it out.
Style="filter: alpha(opacity=25);" provides a neat little washout of most
images when disabling them.

HTH.

-dl
--
David R. Longnecker
http://blog.tiredstudent.com
>Hi,
I am using imagebutton menu on webpage for navigation.
Code adds OnClick attribute and when one clicks on it, redirects him
to that
page. and the same menu appears. This time I want to disable click so
it is
just a button without link.
How can I remove link so that it is not clickable when on that page?
Thank you in advance.

Shailesh


Sep 28 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Mark | last post by:
Hi, I am trying to capture the click event of an ImageButton that exists in a composite server control that I am building. I create the imagebutton in the CreateChildControls routine '...
5
by: J McD | last post by:
Hi I have a DataGrid with an ImageButton column. When I click on an imagebutton I get a postback but it doesn't run the OnImgBtnClick method. I can actually comment out the line where I add this...
1
by: Henke | last post by:
Hello, I have one ImageButton controls which I initialize in Page_Load and declare on class level. ImageButton save = new ImageButton(); save.ImageUrl = "save.gif" save.Click += new...
3
by: Benjamin Gavin | last post by:
Hi all, I recently stumbled upon a bug in the ASP.NET framework handling of ImageButton based postbacks. The issues derives from the fact that IE and Mozilla handle the case of a missing image...
3
by: tshad | last post by:
I was trying to change my asp:button to asp:ImageButton, but got a message saying that ImageButton does not have an onClick function. How do I get the ImageButton call a function? Thanks, ...
13
by: tperri | last post by:
I have an HTML table with several fields like this: <A href="Savings.aspx?category=Food"><asp:imagebutton id="imgFood" ImageUrl="images\buttons\btn-food-i.gif"...
0
by: Oddball | last post by:
I have set up a page with uses two lots of image buttons, one for a collection and one for more images from that collection. I generate all the image buttons on page init (I know, but I...
0
by: Tom Edelbrok | last post by:
I'm using VS 2005 to develop an intranet asp.net web application and I get a weird situation. If I start out with any ASPX page that contains an ImageButton control followed by a TextBox control,...
4
by: Benny Ng | last post by:
Dear All, <input type="checkbox" name="chkAgreement" value="0">I agree with the above terms and conditions <asp:ImageButton ID="ImgBtnSubmit" Runat="server" CausesValidation=True...
2
by: dperren | last post by:
At current, I have a set of dynamically generated image buttons, which are created with this (excert) of code: TableCell tasks = new TableCell(); while (reader.Read()) { ...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.