|
<snip> In the other hand, if I use a subfile with SFLSIZ = SFLPAG, how can I trap multiple selection in the subfile. I mean, what if the user selects a record in one page, press the PageDown key, and selects another record in that page? If I clear the subfile each time the user press the PageUp or PageDown key, the READC won't see the selected records from the previous pages, only the ones in the current page, isn't it? </snip> There are a few ways to do this...(none are that pretty..but gets you past the limitation you mentioned. Any time the program regains control (user presses F key, page key, etc..) Read the selected subfile records & write them to a temp file or to another subfile (which can later be used as a confirmation screen...). When the user requests to process the selections then you just process the temp file or subfile instead of your active displayed subfile page. Decide which is better temp file or subfile prior to doing this...if you don't need a confirmation screen prior to processing I'd go for the temp file (will be better performance wise since using the subfile you'll likely have to define it as subfile size > sfl page....). Plus using the temp file you can pass the information from the interactive process to a batch process if needed. HTH Thanks, Tommy Holden -----Original Message----- From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Charles St-Laurent Sent: Wednesday, March 22, 2006 10:13 AM To: rpg400-l@xxxxxxxxxxxx Subject: self-extending subfile and multiple selection? Hi! I read an article about self-extending subfile to navigate through data. The technique looks quite simple. Each time the user press the PageDown key, or the alternate key associated to the PageDown action, the program takes the control and fills the next subfile page. But if the user press the PageUp key, the system handles it. There is limitations about this technique. The number of records the subfile can contain is still limited to 9999. What if my file contains about 300 000 entries and a maniac user tries to scroll down to the end of the file? In the other hand, if I use a subfile with SFLSIZ = SFLPAG, how can I trap multiple selection in the subfile. I mean, what if the user selects a record in one page, press the PageDown key, and selects another record in that page? If I clear the subfile each time the user press the PageUp or PageDown key, the READC won't see the selected records from the previous pages, only the ones in the current page, isn't it? What's bugging me is the limited size of a self-extending subfile and the case of a multiple selection between pages. Is there a way to have a self-extending subfile that can be greater than 9999 records and handles the selection of multiple records through different pages? Charles St-Laurent
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.