T
TJ
Hi,
Environment : VS.NET 2005/CF 2.0
DataGrid control is used for Pocket PC application.
Q: is there any way I can hide a row programatically in the datagrid?
The thing I want to achive is to mark deleted row somehow.
Well, I know that I can bind DataTable/DataView object into DataSource...
(I can get the deleted records by fetching RowState.Deleted)
However, I would like to do this with custom objects(custom array)...
Custom arrary objects is bound to datasource in datagrid...
If user clicks the row to delete, I would like to mark somehow...
If I remove it from underlying data strcture, there is no way of knowing,
which one has been deleted...
Well, possibly I can think of three approahces...
1. Hide row from the datagrid. I think this is the best solution I can think
of, as long as the I can keep the state of the underlying data structure..
2. I may be able to design a kind of View class that exposes only needed
data to datasource....I meant....something like DataView....However, it seems
that this approach somewhat more than what I need to do in this app...
3. It could be samething to #2,..I think I can maintain two arraylist to
keep track of current and deleted one...Seems not elegant approach, though...
If you know somehow to hide a row programatically in the datagrid,
please share your idea with us.
Thanks,
Environment : VS.NET 2005/CF 2.0
DataGrid control is used for Pocket PC application.
Q: is there any way I can hide a row programatically in the datagrid?
The thing I want to achive is to mark deleted row somehow.
Well, I know that I can bind DataTable/DataView object into DataSource...
(I can get the deleted records by fetching RowState.Deleted)
However, I would like to do this with custom objects(custom array)...
Custom arrary objects is bound to datasource in datagrid...
If user clicks the row to delete, I would like to mark somehow...
If I remove it from underlying data strcture, there is no way of knowing,
which one has been deleted...
Well, possibly I can think of three approahces...
1. Hide row from the datagrid. I think this is the best solution I can think
of, as long as the I can keep the state of the underlying data structure..
2. I may be able to design a kind of View class that exposes only needed
data to datasource....I meant....something like DataView....However, it seems
that this approach somewhat more than what I need to do in this app...
3. It could be samething to #2,..I think I can maintain two arraylist to
keep track of current and deleted one...Seems not elegant approach, though...
If you know somehow to hide a row programatically in the datagrid,
please share your idea with us.
Thanks,