I have written a splash screen which has a bitmap on the top window, and the bottom window consists of the progress bar (a HProgressBar).
It is displayed and everything, but it only shows the progress bar being empty and then full, even though it is only getting through the process slowly. It should be incrementing at certain intervals.
Do I need to send some message saying to display changes in the progress bar.
Here's the creation code :
_hwndPB = CreateWindowEx(0, PROGRESS_CLASS, (LPSTR)NULL, WS_CHILD | WS_VISIBLE | WM_ERASEBKGND, rect.left, rect.bottom-cyVScroll-2, rect.right, cyVScroll, _main, NULL, GetModuleHandle(NULL), NULL);
/**
* Set the range and increment of the progress bar
**/
SendMessage(_hwndPB, PBM_SETRANGE, 0, MAKELPARAM(0, 100));
SendMessage(_hwndPB, PBM_SETSTEP, (WPARAM)1, 0);
And to increment I use :
SendMessage(_hwndPB, PBM_STEPIT, (WPARAM)10, 0);
Please help!
James
It is displayed and everything, but it only shows the progress bar being empty and then full, even though it is only getting through the process slowly. It should be incrementing at certain intervals.
Do I need to send some message saying to display changes in the progress bar.
Here's the creation code :
_hwndPB = CreateWindowEx(0, PROGRESS_CLASS, (LPSTR)NULL, WS_CHILD | WS_VISIBLE | WM_ERASEBKGND, rect.left, rect.bottom-cyVScroll-2, rect.right, cyVScroll, _main, NULL, GetModuleHandle(NULL), NULL);
/**
* Set the range and increment of the progress bar
**/
SendMessage(_hwndPB, PBM_SETRANGE, 0, MAKELPARAM(0, 100));
SendMessage(_hwndPB, PBM_SETSTEP, (WPARAM)1, 0);
And to increment I use :
SendMessage(_hwndPB, PBM_STEPIT, (WPARAM)10, 0);
Please help!
James