Skip to main content

AspNetWrapperBase

Namespace: Wisej.Web.Ext.AspNetControl

Assembly: Wisej.Web.Ext.AspNetControl (4.1.0.0)

Base non-generic class for AspNetWrapperBase.

public abstract class AspNetWrapperBase : IFramePanel

Constructors​

Instance member AspNetWrapperBase()​

Initializes a new instance of AspNetWrapper.

The new instance saves the VIEWSTATE of the ASP.NET page in the Wisej session (see UseSessionViewState). This class is abstract: derive from AspNetWrapper to wrap a specific ASP.NET control.

Example:

The following example creates a wrapper that stores the VIEWSTATE in the page instead of the Wisej session:

public class CalendarWrapper : AspNetWrapper<System.Web.UI.WebControls.Calendar>
{
public CalendarWrapper()
{
this.UseSessionViewState = false;
}
}

Properties​

Instance member IsAsync​

Boolean: Returns whether the current request is an asynchronous postback.

Instance member IsCallback​

Boolean: Returns whether the current request is a callback.

Instance member IsPostBack​

Boolean: Returns whether the current request is a postback.

Instance member Page​

Page: Returns the instance of the internal page used to wrap the ASP.NET control. It is valid only during the processing of the Init or the Load events.

Instance member ScriptManager​

ScriptManager: Returns the instance of the ScriptManager in the AspNetHost.asp page used to wrap AspNet controls.

Instance member UseSessionViewState​

Boolean: Determines whether Wisej saves the VIEWSTATE in memory. The default is true.

Instance member ViewState​

Object: VIEWSTATE saved using Wisej sessions.

Instance member WrappedControl​

WebControl: Returns the instance of the wrapped ASP.NET control. It is valid only during the processing of the Init or the Load events.

Methods​

Protected member CreateHostedControl()​

Creates the wrapped control.

Returns: WebControl.

Protected member OnAbortTransaction(e)​

Fires the AbortTransaction event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnCommitTransaction(e)​

Fires the CommitTransaction event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnDataBinding(e)​

Fires the DataBinding event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnError(e)​

Fires the Error event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnInit(e)​

Fires the Init event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnInitComplete(e)​

Fires the InitComplete event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnLoad(e)​

Fires the Load event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnLoadComplete(e)​

Fires the LoadComplete event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnPreInit(e)​

Fires the PreInit event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnPreLoad(e)​

Fires the PreLoad event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnPreRender(e)​

Fires the PreRender event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnPreRenderComplete(e)​

Fires the PreRenderComplete event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnSaveStateComplete(e)​

Fires the SaveStateComplete event.

ParameterTypeDescription
eEventArgsThe event data.

Protected member OnUnload(e)​

Fires the Unload event.

ParameterTypeDescription
eEventArgsThe event data.

Instance member Update()​

Causes the control to update the corresponding client side widget. When in design mode, causes the rendered control to update its entire surface in the designer.

Calling this method changes the URL of the inner IFrame, which reloads the host page and runs the ASP.NET page life cycle again. Use it to apply property values that are copied to WrappedControl in the Init or Load events.

Example:

The following example reloads a wrapped calendar when its date changes on the server:

public class CalendarWrapper : AspNetWrapper<System.Web.UI.WebControls.Calendar>
{
public DateTime VisibleDate
{
get { return this._visibleDate; }
set
{
if (this._visibleDate != value)
{
this._visibleDate = value;
Update();
}
}
}
private DateTime _visibleDate = DateTime.Today;

protected override void OnLoad(EventArgs e)
{
base.OnLoad(e);
this.WrappedControl.VisibleDate = this._visibleDate;
}
}

Events​

Instance member AbortTransaction​

EventHandler Corresponds to the Page.AbortTransaction event.

Instance member CommitTransaction​

EventHandler Corresponds to the Page.CommitTransaction event.

Instance member DataBinding​

EventHandler Corresponds to the Page.DataBinding event.

Instance member Error​

EventHandler Corresponds to the Page.Error event.

Instance member Init​

EventHandler Corresponds to the Page.Init event in the ASP.NET page life cycle.

Instance member InitComplete​

EventHandler Corresponds to the Page.InitComplete event in the ASP.NET page life cycle.

Instance member Load​

EventHandler Corresponds to the Page.Load event in the ASP.NET page life cycle.

Instance member LoadComplete​

EventHandler Corresponds to the Page.LoadComplete event in the ASP.NET page life cycle.

Instance member PreInit​

EventHandler Corresponds to the Page.PreInit event in the ASP.NET page life cycle.

Instance member PreLoad​

EventHandler Corresponds to the Page.PreLoad event in the ASP.NET page life cycle.

Instance member PreRender​

EventHandler Corresponds to the Page.PreRender event in the ASP.NET page life cycle.

Instance member PreRenderComplete​

EventHandler Corresponds to the Page.PreRenderComplete event in the ASP.NET page life cycle.

Instance member SaveStateComplete​

EventHandler Corresponds to the Page.SaveStateComplete event.

Instance member Unload​

EventHandler Corresponds to the Page.Unload event in the ASP.NET page life cycle.

Inherited By​

NameDescription
AspNetWrapper<T>The AspNetWrapperBase is the base class of all wrapped ASP.NET controls.

Implements​