Hello Everybody i am new in C# i have a some data that in load i my datagrid but anytime the datagrid has new items loaded my vertical scroll bar stay in the same postion !
How to move up my scroll bar anytime the datagrid has new values/ or i click to a new button
The DataGrid class has a method ScrollIntoView
which can be used to scroll a specific item into the visible area of the datagrid.
For example, to scroll to the first item of the datagrid:
datagrid.ScrollIntoView(datagrid.Items[0]);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.