The problem is it doesn't display in a Rad window.
Here's a sampe of what I have on the page.
<
telerik:RadTextBox ID="rTxtPrjSummary" runat="server" Width="550px" MaxLength="255" >
<ClientEvents OnValueChanged="InputValueChanged"/>
</telerik:RadTextBox>
<
div style="margin-left: 75px; margin-top:25px">
<asp:Button ID="btnSave" runat="server" Text="Save" OnClientClick="if(!ProjectSaveButtonClick()) return false;" />
<span style="margin-left: 50px">
<asp:Button ID="btnUndo" runat="server" OnClientClick="if(!UndoBtnClick()) return false;" Style="visibility:hidden" />
</span>
</div>
<script
type
="text/javascript">
var
InputValueHasChanged = false;
function InputValueChanged(sender, args) {
InputValueHasChanged =
true;
var button = $get("<%= btnUndo.ClientID %>");
button.value = 'Clear';
button.style.visibility =
'visible';
}
function UndoBtnClick() {
if (confirm('Are you sure you would like to clear all fields')) {
$find(
"<%= rTxtPrjSummary.ClientID %>").clear();
var button = $get("<%= btnUndo.ClientID %>");
button.style.visibility =
'hidden';
}
}
</
script>
The result of the code is that btnUndo can't be seen on the page, however, if you move the mouse where the button should show, you can click the area and the OnClientClick function UndoBtnClick fires.
I'm having to resort to using the visibility because having problems just disabling the button and then trying to enable the button when the InputValueChanged fires.
Any ideas?
P.S. To see the results, check out http://n-sv.net/projexUI under the menu on the left, click on New Project. Type something in the summary text box and tab out. Once you do that, click to the right of the Save button about an inch and you'll see that the onclientClick fires even you can visually see a button on the screen.