what are grid events ?code for dropdown inside grid and
binding dropdown syntax
Answer Posted / om shivaya namaha
two ways are their to bind the data in the Grid:-
GridID_ItemDatabound()
{
textbox txt =new textbox();
dataset ds=new dataset();
ds=bind data from DataBase;
txt=(textbox)e.item.findcontrol("ddl");
txt.datasource=ds;
txt.databind();
}
like that we can bind data to dropdown list through
ItemCommand also
ItemDatabound will fire when ever we are binding the data to
datagrid it will iterate for each row and each Item
ItemCommand will fire when ever we click on any control in
the datagrid then it will fire but it will refer to the
current row in a datagrid
| Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
Explain exception filters?
What is bson in web api?
What is the recommended approach for asp.net mvc to globally intercept exceptions? What other functionality can be implemented with the approach? : Asp.Net MVC
Which is better union or union all?
What is the difference between abstract class vs interface? Can give me the real time examples?
What is %20 in a url?
How we implement the multiple paypal value with gridview in my website and how we make a payment through Credit Card.
Explain about the Class view window?
In ViewState How much lifespan items stored?
What describes a query?
What are the advantages of passport authentication?
Is asp.net 64-bit enabled? How?
How can u deifne the benefits and limitation of using Viewstate for state management?
Explain form level validation and field level validation?
If you want to bind the columns manually within the asp:datagrid tags what kind of tags you have to add.