RadGrid for ASP.NET

RadGrid Send comments on this topic.
FooterStyle Property
See Also  Example
Telerik.WebControls Namespace > RadGrid Class : FooterStyle Property


Gets a reference to the GridTableItemStyle object that allows you to set the appearance of the footer item in a Telerik RadGrid control.   

 

Namespace: Telerik.WebControls
Assembly: RadGrid (in RadGrid.dll)

Syntax

Visual Basic (Declaration) 
Public Overridable ReadOnly Property FooterStyle As GridTableItemStyle
Visual Basic (Usage)Copy Code
Dim instance As RadGrid
Dim value As GridTableItemStyle
 
value = instance.FooterStyle
C# 
public virtual GridTableItemStyle FooterStyle {get;}

Return Value

A reference to the GridTableItemStyle that represents the style of the footer item in a Telerik RadGrid control.

Example

The following code example demonstrates how to use the SelectedItemStyle property to define a custom style for the footer item in a Telerik RadGrid control.
C#Copy Code
<%@ Page Language="VB" %>

<%@ Register Assembly=
"RadGrid.Net2" Namespace="Telerik.WebControls" TagPrefix="rad" %>

<!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns=
"http://www.w3.org/1999/xhtml" >
<head runat=
"server">
   <title>Untitled Page</title>
</head>
<body>
   <form id=
"form1" runat="server">
   <div>
       <rad:RadGrid
           DataSourceID=
"SqlDataSource1"
           
ID="RadGrid1"
           
runat="server"
           
Skin="None"
           
ShowFooter="true" >
           <FooterStyle BackColor=
"red" />
       </rad:RadGrid>
       <!-- This example uses Microsoft SQL Server and connects  -->
       <!-- to the Northwind sample database. Use an ASP.NET     -->
       <!-- expression to retrieve the connection
string value   -->
       <!-- from the Web.config file.                            -->        
       <asp:SqlDataSource
           ID=
"SqlDataSource1"
           
runat="server"
           
ConnectionString="<<see cref="!:NorthwindConnectionString">$ ConnectionStrings</see>>"
           
SelectCommand="SELECT TOP 5 [CustomerID], [ContactName], [CompanyName] FROM [Customers]">
       </asp:SqlDataSource>
   </div>
   </form>
</body>
</html>
    

Remarks

Use the FooterItemStyle property to control the appearance of the footer item in a Telerik RadGrid control. This property is read-only; however, you can set the properties of the GridTableItemStyle object it returns. The properties can be set declaratively using one of the following methods:

  • Place an attribute in the opening tag of the Telerik RadGrid control in the form Property-Subproperty, where Subproperty is a property of the GridTableItemStyle object (for example, FooterItemStyle-ForeColor).
  • Nest a <FooterItemStyle> element between the opening and closing tags of the Telerik RadGrid control.

The properties can also be set programmatically in the form Property.Subproperty (for example, FooterItemStyle.ForeColor). Common settings usually include a custom background color, foreground color, and font properties.

Requirements

Supported in: 3.0, 2.0, 1.1, 1.0 .NET Framework

See Also