November Happy Hour will be moved to Thursday December 5th.

Class InputPageReference

Simple input type that displays a page selector.

Inheritance
System.Object
InputPageReference
Implements
System.Web.UI.INamingContainer
Namespace: EPiServer.Web.WebControls
Assembly: EPiServer.Cms.AspNet.dll
Version: 11.20.7
Syntax
public class InputPageReference : InputBase, INamingContainer

Constructors

InputPageReference()

Declaration
public InputPageReference()

InputPageReference(IContentRepository)

Declaration
public InputPageReference(IContentRepository contentRepository)
Parameters
Type Name Description
IContentRepository contentRepository

Properties

AutoPostBack

Gets or sets a value indicating whether the control should generate a post back when the value is changed.

Declaration
public bool AutoPostBack { get; set; }
Property Value
Type Description
System.Boolean

true if post back should be generated; otherwise, false.

DisableCurrentPageOption

Gets or sets a value indicating whether you should disable the current page option for the InputPageReference UI.

Declaration
public bool DisableCurrentPageOption { get; set; }
Property Value
Type Description
System.Boolean

true if the current page option should be disabled; otherwise, false.

DisplayControl

Gets the System.Web.UI.WebControls.TextBox that is used to display the selected page on the client.

Declaration
public TextBox DisplayControl { get; }
Property Value
Type Description
System.Web.UI.WebControls.TextBox

The System.Web.UI.WebControls.TextBox that is used to display the selected page on the client.

Gets or sets the pagelink.

Declaration
public PageReference PageLink { get; set; }
Property Value
Type Description
PageReference

The pagelink.

RequireUrlForSelectedPage

A value indicating whether pages that aren't visible on the site should be selectable in the page selection dialog. When true only pages that is visible on site will be selectable.

Declaration
public bool RequireUrlForSelectedPage { get; set; }
Property Value
Type Description
System.Boolean

true if only pages visible on the site are selectable; otherwise, false.

ValueControl

Gets the System.Web.UI.HtmlControls.HtmlInputHidden that is used to store the value on the client.

Declaration
public HtmlInputHidden ValueControl { get; }
Property Value
Type Description
System.Web.UI.HtmlControls.HtmlInputHidden

The System.Web.UI.HtmlControls.HtmlInputHidden that is used to store the value on the client.

Methods

CreateChildControls()

Creates a HtmlInputHidden control to store the value and a disabled TextBox to show the selected value to the user. Also creates a button that opens the page browser dialog.

Declaration
protected override void CreateChildControls()

OnPreRender(EventArgs)

On the PreRender event we update the display field.

Declaration
protected override void OnPreRender(EventArgs e)
Parameters
Type Name Description
System.EventArgs e

An System.EventArgs object that contains the event data.

Events

ValueChanged

Occurs when the value of the input has changed.

Declaration
public event EventHandler ValueChanged
Event Type
Type Description
System.EventHandler
Remarks

For it to trigger you need to set AutoPostBack = true as well.

Implements

System.Web.UI.INamingContainer

Extension Methods