Save the previous position of the Vertical Scroll?

Thiago_Sase wrote on 10/10/2024, 2:16 PM

@jetdv Sir, please, if possible, in my custom command I'm using the AutoScroll. 

this.AutoScroll = true;

Which lines of code I should write to make the Scroll always saves its last vertical position when I switch the layout window?

And when I come back to the layout window that has the extension, it will load the previous position of the vertical scroll? 

Then, the vertical scroll position will never back to its default start point when I switch layouts window. 

Comments

jetdv wrote on 10/10/2024, 2:23 PM

I believe to do that you will have to manually get and save the location on losing focus and the reset it to that saved value when focus comes back. Or get and save the location as the scrolling occurs and then reset it back to the last value focus returns to that window.