Hello,
How can you show/hide the three header buttons through javascript.
I have tried a bunch of things and none have worked.
Thank you,
Brandon
Hi Brandon,
WebDialogWindow does not expose public references to buttons. However, its header has internal variables _closeButton, _minButton and _maxButton (their type is $IG.DialogButton). That object has standard ajax method get_element(). It is also possible to find reference to that html element by traversing within DOM of dialog/header. You also may try to use debugger and check all (internal) member variables and functions.Below is example to acces html element of min-button.
<script type="text/javascript">function hideButton(){ var dialog = $find('<%=WebDialogWindow1.ClientID%>'); var header = dialog.get_header(); //debugger; if(!header) return; var minButton = header._minButton; if(!minButton) return; var style = minButton.get_element().style; style.display = 'none'; style.visibility = 'hidden';}</script>
<input type="button" value="hideButton" onclick="hideButton()" /><ig:WebDialogWindow ID="WebDialogWindow1" runat="server" Height="198px" Width="450px"> <Header> <MinimizeBox Visible="True"></MinimizeBox> </Header></ig:WebDialogWindow>