|
See if this works for you: (use fixed font, copy & paste if you so wish) ** WRITTEN BY : Booth Martin * ** DATE WRITTEN : 12/2005 * **--------------------------------------------------------------------* FSFLSORTFM cf e workstn F sfile(SFL1 : SF1NUM) FSFLSORTP if e disk **====================================================================* ** MAINLINE-BEGIN * **====================================================================* C exsr S1Fill * Display screen. C exsr S1Main * Exit. C eval *inlr = *on **====================================================================* ** MAINLINE-END * **====================================================================* *-------------------------------* Sub-Routine * * S1Main() *---------------* * Screen - Main processing. * *-----------------------------------------------* C S1Main begsr * Loop until exit. C dow *inkc = *off * Display screen. C write S1CMD C exfmt S1 C select * F3=Exit. C when *inkc = *on C endsl C enddo C endsr *-------------------------------* Sub-Routine * * S1Fill() *---------------* * Screen - Fill screen. * *-----------------------------------------------* C S1Fill begsr * Clear subfile. C eval *in50 = *on C write S1 C eval *in50 = *off * Fill SFL. C eval SF1NUM = *zero * Read the file. C *start setll SFLSORTP C read(e) SFLSORTP C dow NOT %eof C eval SF1NUM = SF1NUM + 1 C write(e) SFL1 C read(e) SFLSORTP C enddo * No records? C if SF1NUM = *zero C eval SF1NUM = 1 C eval *in61 = *on C write(e) SFL1 C endif * Save values. C eval SF1RECS = SF1NUM C eval SF1TOP = 1 C endsr steema@xxxxxxxxxxxxx wrote:
Thanks Booth, but is there one that is more simple to base on?There's lots of samples on the Internet in various places. Here's a couple: http://www.martinvt.com/Code_Samples/code_samples.htm http://tinyurl.com/a4t6c steema@xxxxxxxxxxxxx wrote:HI I am looking for some code for a simple subfile update program. Idid the display. Thanks, Steve-- ----------------------------------- Booth Martin http://martinvt.com ----------------------------------- -- This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list To post a message email: RPG400-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/rpg400-l or email: RPG400-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/rpg400-l.
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.