System.Web.UI.WebControls.ControlParameter Class

Binds the value of a property of a System.Web.UI.Control to a parameter object.

See Also: ControlParameter Members

Syntax

[System.ComponentModel.DefaultProperty("ControlID")]
public class ControlParameter : Parameter

Remarks

You can use the System.Web.UI.WebControls.ControlParameter class to bind the value of a System.Web.UI.Control property, such as ListControl.SelectedValue or ListControl.SelectedIndex, to a parameter that is used in a parameterized SQL query, business object method, or filtering expression.

The System.Web.UI.WebControls.ControlParameter class provides two properties in addition to those inherited from the System.Web.UI.WebControls.Parameter class: ControlParameter.ControlID and ControlParameter.PropertyName. The ControlParameter.ControlID property identifies which System.Web.UI.Control instance to bind to and the ControlParameter.PropertyName property identifies the public property of the System.Web.UI.Control from which the System.Web.UI.WebControls.ControlParameter class retrieves a value.

Requirements

Namespace: System.Web.UI.WebControls
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0