Retention of display position after processing.
-
- Profound User
- Posts: 20
- Joined: Thu Dec 15, 2011 3:05 pm
- First Name: alex
- Last Name: amores
- Company Name: summit consulting
- City: lakeland
- State / Province: Florida
- Zip / Postal Code: 33802-0988
- Country: United States
- Contact:
Retention of display position after processing.
We have one record format on a display file that causes vertical scrolling. The user has to scroll down to enter data on the elements. After hitting the enter key or clicking on the button, the control passes back to the RPG program for processing and re-display the record formats. But this time the screen scrolls up hiding the last element where the user is working. How can we retain this last position of the display? Any help is appreciated.
-
- Profound User
- Posts: 20
- Joined: Thu Dec 15, 2011 3:05 pm
- First Name: alex
- Last Name: amores
- Company Name: summit consulting
- City: lakeland
- State / Province: Florida
- Zip / Postal Code: 33802-0988
- Country: United States
- Contact:
Re: Retention of display position after processing.
This condition happens when you are in a tabular screens and each individual tab is a call to an independent program. Found a work around to prevent the screen from scrolling down. It would be nice if a "Place Cursor" properly is made available to a non subfile grid screen. The set focus will work, but is available only to certain widgets and if you hide that widget, set focus will not work anymore.
- David
- Profound Logic Staff Member
- Posts: 690
- Joined: Fri Jan 04, 2008 12:11 pm
- First Name: David
- Last Name: Russo
- Company Name: Profound Logic Software
- Contact:
Re: Retention of display position after processing.
Glad you found a workaround. I think you're right -- setting focus is the only way to make it scroll things into view, and there are some limitations there as you say.
It might be possible to add a new property where you can specify a widget to 'scroll into view' -- our development team will take this into consideration for a future update.
It might be possible to add a new property where you can specify a widget to 'scroll into view' -- our development team will take this into consideration for a future update.
- David
- Profound Logic Staff Member
- Posts: 690
- Joined: Fri Jan 04, 2008 12:11 pm
- First Name: David
- Last Name: Russo
- Company Name: Profound Logic Software
- Contact:
Re: Retention of display position after processing.
It's possible to call the necessary JavaScript code directly to scroll any item into view.
See here:
https://developer.mozilla.org/en-US/doc ... llIntoView
In PUI, you could call this from the record format's 'onload' event, like this:
See here:
https://developer.mozilla.org/en-US/doc ... llIntoView
In PUI, you could call this from the record format's 'onload' event, like this:
Code: Select all
// Use 'id' property (case-sensitive) of widget you'd like to scroll into view.
getObj('YourWidgetId').scrollIntoView(true);
Who is online
Users browsing this forum: No registered users and 6 guests