To add the two Columns in one, in GridView using TemplateField

Amatya
Posted by Amatya under ASP.NET category on | Points: 40 | Views : 500
Here we are merging two column value in one column which have a header name Country


<asp:TemplateField HeaderText="Country">
<ItemTemplate>
<asp:Label ID="Label1" runat="server" Text='<%#Eval("CountryGroup1")+ " " + Eval("CountryGroup2")%>' ></asp:Label>
</ItemTemplate>
</asp:TemplateField>


Thanks Hope it will be useful

Comments or Responses

Login to post response