Download Now Code Base AsyncDocs Contact Us
asyncModalLayer
liveDemo
  • Clicking "Show the AsyncModalLayer" will show an AsyncModalLayer used to focus the attention of the user.
  • It also prevents interaction with anything not on the modal layer.

Please show the modal layer.

Description

The AsyncModalLayer is a Async-Enabled, UI blocking panel. Anytime it is shown it will block the underlying UI. It closes whenever it is hidden (either by the user or programmatically). You are free to place whatever controls you want within the modal layer.



Features
  • Allows you to show and hide the modal layer during an AsyncCallback.
  • Fully customizable look and feel.
  • Easily chain modal layers together to create "wizard" like operations.
   
<%@ Register Assembly="AsyncControls" Namespace="DelvingWare.AsyncControls" TagPrefix="dw" %>

<dw:AsyncModalLayer runat="server" ID="mdlMain" 
Visible="false" 
CssClass="modalLayer">    
    <dw:AsyncPanel runat="server" ID="pnlMain">
        <div class="modalInstruct">Please complete the form before continuing (or just click "No Thanks").</div>
        <p style="text-align:center">
        <table>
            <tr>
            <td>Name:</td>
                <td>
                <dw:AsyncTextBox runat="server" ID="txtName" 
                EnableValidation="Enabled"
                ErrorMessage="Enter a name."
                ErrorMessageCssClass="errorMsg" />
                </td>
            </tr>
            <tr> 
            <td>Nickname:</td>
                <td>
                <dw:AsyncTextBox runat="server" ID="txtNickName" 
                EnableValidation="Enabled"
                ErrorMessage="Enter a nickname."
                ErrorMessageCssClass="errorMsg" />
                </td>
            </tr>
            </table>
        </p>
        <div class="innerLayer" align="center">                    
            <dw:AsyncButton runat="server" ID="btOne" 
            CausesValidation="true"
            OnClick="btOne_Click"
            CssClass="greyButton">OK</dw:AsyncButton>
            
            <dw:AsyncButton runat="server" ID="bttwo" 
            CausesValidation="true" 
            OnClick="btTwo_Click"
            CssClass="greyButton">Reset Fields</dw:AsyncButton>            
        </div>
        <br/>
        <div align="center">
            <dw:AsyncLinkButton runat="server" ID="lnkOne" 
            OnClick="lnkOne_Click" 
            CssClass="linkButton">No Thanks</dw:AsyncLinkButton>
        </div>
    
    </dw:AsyncPanel>

</dw:AsyncModalLayer>

<dw:AsyncLabel runat="server" ID="lblMain" 
RenderMode="Paragraph">Please show the modal layer.</dw:AsyncLabel>

<dw:AsyncButton runat="server" ID="btMain" 
Text="Show the AsyncModalLayer" 
OnClick="btMain_Click"
CssClass="greyButton"/>