I want to scroll a window and get the position of the scrollbar. Here is my code:
H := $10D6E;
for I := 0 to 100 do
SendMessage(H, WM_VSCROLL, SB_LINEDOWN, 0);
SInfo.cbSize := SizeOf(SInfo);
SInfo.fMask := SIF_TRACKPOS;
GetScrollInfo(H, SB_THUMBPOSITION, SInfo);
But everytime I get still number (4509807) in the nTrackPos. How could GetScrollInfo used to get the current scroll position? The code is written in Delphi. I need to know how to get current wnidow position from GetScrollInfo function. The window that I'm trying this code is Internet Explorer.