Showing posts from February, 2005

Scrolling DataGrid (.Net CF)

this is what i found on the net on how to scroll a data grid
//Get a reference to the scroll bars in the data grid
VScrollBar vsb = (VScrollBar)grd.GetType().GetField("m_sbVert", BindingFlags.NonPublic|BindingFlags.GetField|BindingFlags.Instance).GetValue(grd);

HScrollBar hsb = (HScrollBar)grd.GetType().GetField("m_sbHorz", BindingFlags.NonPublic|BindingFlags.GetField|BindingFlags.Instance).GetValue(grd);

hsb.Value=hsb.Maximum ;
vsb.Value=vsb.Maximum ;

if anyone knows how to do the same for a ListView please let me know