Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Nov 16, 2012 02:13 PM by banksidepoet
Nov 16, 2012 01:40 PM|LINK
I am using a Response.Redirect in the Click event of a LinkButton to navigate to another page.
If X condition is true, I want to be able to disable the LinkButton's functionality:
Don't worry about the IF statement, just how do I stop a LinkButton behaving like a link?
Nov 16, 2012 01:51 PM|LINK
first set LinkButton.Enabled to false....and then on top of it apply your custom css using LinkButton.CssClass to have your interested CSS....
Nov 16, 2012 01:55 PM|LINK
Add a class
Use following code in code behind :
if condition then
LinkButton1.CssClass = "asLabel"
LinkButton1.Enabled = False
Nov 16, 2012 02:13 PM|LINK