System.Web 2.0.0.0 System.Web.UI.Control System.Web.UI.ToolboxData("<{0}:View runat="server"></{0}:View>") System.ComponentModel.Designer("System.Web.UI.Design.WebControls.ViewDesigner, System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a", "System.ComponentModel.Design.IDesigner") System.Web.UI.ParseChildren(false)

In this topic:

Introduction

Declarative Syntax

## Introduction

The control is a container for a group of controls. A control must always be contained within a control. Only one control at a time can be defined as the active view within a control.

The property specifies the active control within the collection of a control. The active view control is rendered to the client, as long as the containing control is visible. Use the property to determine whether a control and its child controls are visible on the page and rendered to the client.

A control can contain controls of any type, including other controls. A control does not support any style properties. To apply styles to a control, add one or more controls to the control.

The class provides the and events. The event is raised when the current control becomes the active view. This occurs when the value of the property changes or the method is called to specify a different control. For example, if View1 is the active view within a control, when the property changes to specify View2, the event is raised for View2 and the event is raised for View1.

To allow users to navigate between multiple controls within a control, you can add a or control to each control. Set the or control's CommandName property to the ID of the control to navigate to. For a code example, see .

For more information on manipulating controls within a control, see the topic.

## Declarative Syntax

`<asp:View EnableTheming="True|False" EnableViewState="True|False" ID="string" OnActivate="Activate event handler" OnDataBinding="DataBinding event handler" OnDeactivate="Deactivate event handler" OnDisposed="Disposed event handler" OnInit="Init event handler" OnLoad="Load event handler" OnPreRender="PreRender event handler" OnUnload="Unload event handler" runat="server" SkinID="string" Visible="True|False" />`

Represents a control that acts as a container for a group of controls within a control.

- Constructor
  To be added.

  Initializes a new instance of the class.

  2.0.0.0
- Event
  System.EventHandler

  The event is raised when the current control becomes the active view. This occurs when the value of the property changes or the method is called to specify a different control. For example, if View1 is the active view within a control, when the property changes to specify View2, the event is raised for View2 and the event is raised for View1.

  Occurs when the current control becomes the active view.

  2.0.0.0
- Event
  System.EventHandler

  The event is raised when the current active control becomes inactive. A control becomes inactive when the value of the property changes or the method is called to specify a different control. For example, if View1 is the active view within a control, when the property changes to specify View2, the event is raised for View1 and the event is raised for View2.

  Occurs when the current active control becomes inactive.

  2.0.0.0
- Method
  System.Void ``

  The event is raised when the current control becomes the active view.

  Raises the event of the control.

  An that contains the event data. 2.0.0.0
- Method
  System.Void ``

  The event is raised when the current active control becomes inactive.

  Raises the event of the control.

  An that contains the event data. 2.0.0.0
- Property
  System.Boolean To be added.

  Use the property to determine whether the current control is visible and rendered to the client. For a control to be visible on the rendered page, it must be the active view in its containing control, and the containing control must be visible. If the containing control is not visible on the page, or if the control is not the active view, then the control and its child controls are not rendered.

  The property is set internally based on the visibility and active view for the containing parent control. If you set this property at run time, an exception is thrown. If you set the property at design time, any changes to the property are ignored.

  Gets or sets a value that indicates whether the control is visible.

  2.0.0.0