System.Web.UI.WebControls Namespace FormView Class
.NET Framework version 2.0
Returns a FormViewRow object that represents the pager row displayed at the bottom of the FormView control.
Script |
[ FormViewRow variable = ] FormView.BottomPagerRow |
The property is read only with no default value.
When paging is enabled (when the AllowPaging property is set to true), an additional row called the pager row is automatically displayed in the FormView control.
The pager row contains controls that allow the user to navigate to other records, and can be displayed at the top, the bottom, or both the top and bottom of the control. Use the BottomPagerRow property to programmatically access the FormViewRow object that represents the bottom pager row in the FormView control.
NOTE: The BottomPagerRow property is available only after the FormView control creates the bottom pager row in the ItemCreated event.
This property is commonly used when you need to programmatically manipulate the bottom pager row, for example when adding custom content. Any modification to the BottomPagerRow property must be performed after the FormViewRow object that represents the bottom pager row has been created; otherwise, the FormView control overwrites any changes.
The following example demonstrates how to programmatically set the style properties of the BottomPagerRow in the FormView control at run time.
void chgSelectedProps ( Object src, EventArgs e ) {
if ( myFormView.BottomPagerRow != null ) {
myFormView.BottomPagerRow.BackColor = System.Drawing.Color.Khaki;
myFormView.BottomPagerRow.ForeColor = System.Drawing.Color.Maroon;
myFormView.BottomPagerRow.Font-Bold = true;
}
}
Sub chgSelectedProps ( src As Object, e As EventArgs )
If Not ( myFormView.BottomPagerRow Is Nothing ) Then
myFormView.BottomPagerRow.BackColor = System.Drawing.Color.Khaki
myFormView.BottomPagerRow.ForeColor = System.Drawing.Color.Maroon
myFormView.BottomPagerRow.Font-Bold = True
End If
End Sub |
|
C# |
VB |
FormViewRow FooterRow HeaderRow Row TopPagerRow Specifying Paging Behavior in a FormView Control