Hi
I would like to add two column values in a third column and I thought that a template field was the way to do this but maybe I'm wrong, I tried this
<asp:BoundField DataField="exp_budget2_cy" DataFormatString="{0:#,##0;(#,##0);0}" HeaderText="CY Budget Revised"
ReadOnly="True" SortExpression="exp_budget2_cy">
<ItemStyle HorizontalAlign="Right" Wrap="False" />
<HeaderStyle HorizontalAlign="Center" Width="80px" />
</asp:BoundField>
<asp:BoundField DataField="exp_adjust" HeaderText="NY Adjustment" SortExpression="exp_adjust" DataFormatString="{0:#,##0;(#,##0);0}">
<ItemStyle HorizontalAlign="Right" Wrap="False" />
<HeaderStyle HorizontalAlign="Center" Width="80px" />
</asp:BoundField>
<asp:TemplateField HeaderText="NY Proposed Budget">
<EditItemTemplate>
<asp:Label ID="Label1" runat="server"></asp:Label>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label1" runat="server" Text='<%# ("exp_budget2_cy"+"exp_adjust", "{0:#,##0;(#,##0);0}") %>'></asp:Label>
</ItemTemplate>
<HeaderStyle HorizontalAlign="Center" Width="80px" />
<ItemStyle HorizontalAlign="Right" />
</asp:TemplateField>
Any advice would be much appreciated. Thanks
Dave
I would like to add two column values in a third column and I thought that a template field was the way to do this but maybe I'm wrong, I tried this
<asp:BoundField DataField="exp_budget2_cy" DataFormatString="{0:#,##0;(#,##0);0}" HeaderText="CY Budget Revised"
ReadOnly="True" SortExpression="exp_budget2_cy">
<ItemStyle HorizontalAlign="Right" Wrap="False" />
<HeaderStyle HorizontalAlign="Center" Width="80px" />
</asp:BoundField>
<asp:BoundField DataField="exp_adjust" HeaderText="NY Adjustment" SortExpression="exp_adjust" DataFormatString="{0:#,##0;(#,##0);0}">
<ItemStyle HorizontalAlign="Right" Wrap="False" />
<HeaderStyle HorizontalAlign="Center" Width="80px" />
</asp:BoundField>
<asp:TemplateField HeaderText="NY Proposed Budget">
<EditItemTemplate>
<asp:Label ID="Label1" runat="server"></asp:Label>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label1" runat="server" Text='<%# ("exp_budget2_cy"+"exp_adjust", "{0:#,##0;(#,##0);0}") %>'></asp:Label>
</ItemTemplate>
<HeaderStyle HorizontalAlign="Center" Width="80px" />
<ItemStyle HorizontalAlign="Right" />
</asp:TemplateField>
Any advice would be much appreciated. Thanks
Dave