Welcome! Log In Create A New Profile

Advanced

WM21 - tall window scrolling

Posted by Bill Quinn 
Bill Quinn
WM21 - tall window scrolling
December 20, 2017 02:27PM
I have a window with 4 tables stacked vertically followed by a button. I've changed the height of the window so all the controls fit and checked the "Automatic scrollbar" option for the window. Everything works great except when the window has been scrolled to the bottom and the button is pressed, I would like to automatically scroll back to the top. The only way I've found to do this is to place an edit control at the top of the window and do a Setfocus(). Is there a better way?

Thanks, Bill
Bill Quinn
Re: WM21 - tall window scrolling
December 20, 2017 04:50PM
I've found that by moving the edit control beyond the top edge of the window gives me the scroll up that I need without a cursor showing in the edit control, but....is there a better way of scrolling up a window that has automatic scrolling?

Bill
Rik
Re: WM21 - tall window scrolling
December 27, 2017 12:12PM
Hello Bill,

I did this with a looper, have a look at this:
[doc.windev.com]

Regards,
Rik
Bill Quinn
Re: WM21 - tall window scrolling
December 27, 2017 03:47PM
Thanks Rik! I think I looked at that function before but didn't think it would apply to an entire window. It does and works perfectly on both android and ios. Thanks!

Bill
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: