I am working on maintaining page position for an edit favorites page. Alex helped me with it a couple of weeks ago and it works like a charm.
window.savedPos = window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 5; (For onSubmit)
if (window.savedPos != null) {
setTimeout(function() {
window.scrollTo(0, window.savedPos);
}, 100);
}
(For onLoad)
However, the main grid for the screen has a scroll bar and if a user is at the bottom of the grid and the page loads, the scrollbar is reset to the top. I need to retrieve and set the scrollbar position for the grid on when the page reloads. There is a property on it called scroll tool tip, but I don't know how to access the value of it from javascript. Any suggestions?
Determine and set scroll position of a grid on page load.
-
- Profound User
- Posts: 36
- Joined: Thu Jan 02, 2014 6:20 pm
- First Name: Brian
- Last Name: Lannoye
- Company Name: Dealertrack Technologies
- Phone: 801.617.1806
- State / Province: Utah
- Zip / Postal Code: 84095
- Country: United States
- Contact:
-
- Profound User
- Posts: 82
- Joined: Fri Jun 29, 2012 2:33 pm
- First Name: Antonio
- Last Name: Ruballos
- Company Name: Profound Logic
- Contact:
Re: Determine and set scroll position of a grid on page load.
There is a property called "position at top" for the subfile grid that allows you to set the scrollbar position for the subfile grid by choosing what record is shown in the first row of the grid. If you could send us a JSON screenshot of the screne in question you are working with, we can take a look at it and get a better idea of what you are describing and see if this is what you need.
To get a JSON screenshot simply open up your screen in the designer, select "Save As" at the top of the designer, select the local tab and save the file on your Local PC. Attach that file to a post here.
To get a JSON screenshot simply open up your screen in the designer, select "Save As" at the top of the designer, select the local tab and save the file on your Local PC. Attach that file to a post here.
-
- Profound User
- Posts: 36
- Joined: Thu Jan 02, 2014 6:20 pm
- First Name: Brian
- Last Name: Lannoye
- Company Name: Dealertrack Technologies
- Phone: 801.617.1806
- State / Province: Utah
- Zip / Postal Code: 84095
- Country: United States
- Contact:
Re: Determine and set scroll position of a grid on page load.
Here you go.
Thanks.
Thanks.
- Attachments
-
- MyFavoritesDDS.json
- (346.78 KiB) Downloaded 271 times
Who is online
Users browsing this forum: No registered users and 2 guests