Skip to main content
Tab

ASPxFormLayout.ClientVisible Property

Gets or sets a value that specifies the initial visibility state of an editor on the client.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.2.dll

Declaration

[DefaultValue(true)]
public bool ClientVisible { get; set; }

Property Value

Type Default Description
Boolean true

true to make an editor initially displayed on the client; false to render the editor into the web page, but make it initially hidden on the client side.

Remarks

Use the ClientVisible property to define an editor’s initial visibility state. The editor’s visibility can then be dynamically changed on the client side using the ASPxClientControlBase.SetVisible method.

Note

If an editor’s server Visible property is set to false, the editor is not rendered into the web page at all, so it can’t be manipulated on the client side.

Example

The following example illustrates how to use the ClientVisible property.

<dx:ASPxFormLayout ID="ASPxFormLayout1" runat="server" Width="30%" ClientInstanceName="fl" ClientVisible="false">
    <Items>
        <dx:LayoutItem Caption="Layout Item1" ColSpan="1" ShowCaption="True">
            <LayoutItemNestedControlCollection>
                <dx:LayoutItemNestedControlContainer runat="server">
                </dx:LayoutItemNestedControlContainer>
            </LayoutItemNestedControlCollection>
        </dx:LayoutItem>
        <dx:LayoutItem Caption="Layout Item2" ColSpan="1" ShowCaption="True">
            <LayoutItemNestedControlCollection>
                <dx:LayoutItemNestedControlContainer runat="server">
                </dx:LayoutItemNestedControlContainer>
            </LayoutItemNestedControlCollection>
        </dx:LayoutItem>
    </Items>
</dx:ASPxFormLayout>

<br />
<dx:ASPxButton ID="ASPxButton1" runat="server" Text="ASPxButton" AutoPostBack="False">
    <ClientSideEvents Click="function(s, e) {
        fl.SetVisible(!fl.GetVisible());
    }" />
</dx:ASPxButton>
See Also