button on a datagrid cell
-
i want to make a cell of a datagrid as a button... i am using .NewRow predefined function to add a new row.. i am not using any data adapter neither data set... i am adding new row straight to the datagrid... what should i need to do... please help me... i am using vb.net 2002. if ever, much better if you can give me sample codes. thanks!
-
i want to make a cell of a datagrid as a button... i am using .NewRow predefined function to add a new row.. i am not using any data adapter neither data set... i am adding new row straight to the datagrid... what should i need to do... please help me... i am using vb.net 2002. if ever, much better if you can give me sample codes. thanks!
Depending on where the new row is added, you can use a RowDoubleClick or Click event to process the data in that field. For example, if the row is added to the end of the data grid, you can use a collection of the rows and access the last element of the collection array directly. Then, you could systematically go through the cells you want to extract the data out of by passing the column name to one of the functions provided by the data grid class (something like SelectedIndex() or Index() and then you pass the name of the column). Hope this helps.
-
Depending on where the new row is added, you can use a RowDoubleClick or Click event to process the data in that field. For example, if the row is added to the end of the data grid, you can use a collection of the rows and access the last element of the collection array directly. Then, you could systematically go through the cells you want to extract the data out of by passing the column name to one of the functions provided by the data grid class (something like SelectedIndex() or Index() and then you pass the name of the column). Hope this helps.
i already know about that... but i really need to put a button in a cell. but thanx anyway...
-
i already know about that... but i really need to put a button in a cell. but thanx anyway...
Oh, sorry. Didn't understand what you meant. Good luck!