以下のように、asp.net WebフォームにTelerik RadGridがあります。
MasterTableView
DetailTables -> GridTableView
その詳細テーブルには、以下のような列があります。
<telerik:GridTableView runat="server" DataKeyNames="ID,Customer_ID,CardType_ID,OrderStatus_ID"
DataSourceID="sdsOrders" AllowFilteringByColumn="True"
AllowMultiColumnSorting="True" AllowSorting="True" ShowFooter="True" OnDataBinding="GridTableView_DataBinding">
...
<telerik:GridBoundColumn DataField="TotalPrice" DataType="System.Int32" FilterControlAltText="Filter TotalPrice column"
HeaderText="TotalPrice" SortExpression="TotalPrice"
UniqueName="TotalPrice" AllowFiltering="False" FooterText="Sum: " Aggregate="Sum">
<HeaderStyle HorizontalAlign="Center" VerticalAlign="Middle" Width="100px" />
<ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" Width="100px" />
</telerik:GridBoundColumn>
フッターのフッターテキスト(Sum)とその(Sum)の色を変えたいです。
MasterTableView の DataBoundColumns の場合、以下のコードが機能します。
protected void GridTableView_DataBinding(object sender, EventArgs e)
{
GridBoundColumn TotalPrice = grdCustomers.MasterTableView.GetColumnSafe("TotalPrice") as GridBoundColumn;
TotalPrice.FooterAggregateFormatString = "<span class=\"AggregateTitleColor\">Sum : </span>" + "{0:#,0 ;#,0- }";
TotalPrice.FooterStyle.ForeColor = ColorTranslator.FromHtml("blue");
}
DetailTable の TotalPrice のコードを書き直すにはどうすればよいですか?
前もって感謝します