Hi,
The reason script is not working because there is no property called
Enabled in JavaScript,
every one make this mistake. To disable a control use Disabled property
See the following link for HTML reference
http://msdn.microsoft.com/library/de...node_entry.asp
Can you see a property called Enabled...????
Hope the following code might help you...
<script language="JavaScript">
function test()
{
document.getElementById("Button1").disabled=true
}
</script>
<body onload="test()">
<form id="form1" runat="server" >
<div>
<br />
<asp:Button ID="Button1" runat="server" Text="Button" /></div>
</form>
</body>
vinu
"akis" <ak**@discussions.microsoft.com> wrote in message
news:E1**********************************@microsof t.com...
Hello,
I have one button in the aspx page called btnSubmit which i need to
disable
using javascript
the document.getElementById("btn_Submit").Enabled=fals e returns an error
and the
document.getElementById('_ctl0_ContentPlaceHolder1 _btnSubmit').Enabled=false
works fine but how can i get that _ctl0_ContentPlaceHolder1_btnSubmit' ?
now
i looked in the "view source" of the actual page
thanks,
akis