How to add controls in datagrid

Questions by kbs.shohaib

Showing Answers 1 - 15 of 15 Answers

anjani

  • Jul 15th, 2008
 

hi
 
To add the controls in datagrid right click on the data grid it shows the smart tag from which u select the edit column then a window appears in which certain fields r there like:

1. BoundField
2. CheckBoxField
3. HyperlinkField
4. ImageField
5. ButtonField
6. CommandField
7. TemplateField

select any of the field according to ur proj req like if u select the BoundField the it will add the "Button" in the Row in the same way u can add other controls by using these fields.

For adding controls in datagrid, first you have to add available templates of datagrid whichever you want that is, ItemTemplate, EditTemplate.

In that template you can write any ASP control normally.

  Was this answer useful?  Yes

dsk4u

  • Nov 24th, 2008
 

To add Controls in Datagrid, take template column and add new controls in that template column.

  Was this answer useful?  Yes

Saravan987

  • Nov 29th, 2009
 

If you want to add the controls on the grid, you can use item template.

Example:

<asp:TemplateField>
<ItemTemplate>
<asp:CheckBox ID="Chk" runat="server" />
</ItemTemplate>
</asp:TemplateField>

nymishore

  • Nov 30th, 2009
 

Take template column and and Insert the Controls what ever you want to add the dataGrid, and find those control in Grid Itembound/ItemCommand.

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions