enable/disable question

  • Thread starter Thread starter Dave
  • Start date Start date
D

Dave

Is it possible to disable the something like below? I dont see an
enabled property...

////////////////////////////////////////////////

<a id="FurtherActionHyperlink" href="#"
onclick="window.open('SORFollup.aspx?SORID=<%# Eval("SORID") %>', '',
'toolbar=0, height=320,width=375,resizable=0,scrollbars=0');return
false">
Further Action</a>


//////////////////////////////////////////////

if not, any suggestions on how to try launching a popup in the same
manner?

Thanks
 
Is it possible to disable the something like below?  I dont see an
enabled property...

////////////////////////////////////////////////

<a id="FurtherActionHyperlink" href="#"
onclick="window.open('SORFollup.aspx?SORID=<%# Eval("SORID") %>', '',
'toolbar=0, height=320,width=375,resizable=0,scrollbars=0');return
false">
Further Action</a>

//////////////////////////////////////////////

if not, any suggestions on how to try launching a popup in the same
manner?

Thanks

Try with javascript.
document.getElementById('<%FurtherActionHyperlink.ClientId
%>').disabled = true;

Best regards.
 
Sorry, please be a little more specific. I don't know Java. I did
neglect to say that I need to be able to disable it in C#;conditional
on checkbox control.
 
Sorry, please be a little more specific.  I don't know Java.  I did
neglect to say that I need to be able to disable it in C#;conditional
on checkbox control.

Hello:
Java is no javascript ;)
Ok, I haven't try this code, but should be something like this. In
your code behind:

protected void Page_Load(object sender, EventArgs e){
if(myCheckBox.Cheked){
ClientScript.RegisterStartupScript(GetType(), "DisableLink",
"document.getElementById('" + FurtherActionHyperlink.ClientId +
"').disabled = true;", true);
}
}

By the way:
http://en.wikipedia.org/wiki/Java_(programming_language)
http://en.wikipedia.org/wiki/JavaScript
Best regards.
 
Back
Top