Hi everyone,

I have searched the forum but found nothing related to my problem.

I'm using a horizontal scroll bar in a dialog box. I want to process SB_PAGELEFT message.
When WM_HSCROLL arrives mesage i check LOWORD(wParam) and if it is SB_PAGELEFT i'm trying to get position of a scroll bar. But GetScrollInfo returns nothing.

Here is the source:

Code:
HWND slider = GetDlgItem(hwndDlg,IDC_SLIDER);
SCROLLINFO info;
ZeroMemory(&info,sizeof(info));
info.cbSize = sizeof(SCROLLINFO);
info.fMask = SIF_ALL;
GetScrollInfo(slider,SB_CTL,&info);
SetDlgItemInt(hwndDlg,IDC_EDIT1,info.nPos,false);
info.nPos is invalid.

On SB_THUMBPOSITION I'm using HIWORD(wParam) as a position of a scroll bar. Why i can't get the same on SB_PAGELEFT is a big mystery to me.