× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: RE: Saving program variables?
  • From: "Jim Langston" <jlangston@xxxxxxxxxxx>
  • Date: Wed, 8 Aug 2001 15:36:21 -0700
  • Importance: Normal

Declare all your variables to be used and saved in the program into one data
structure.  Then map one huge character variable over the data structure,
and write/read that one variable/field.

You can even map Database fields into a data structure, so this shouldn't be
a problem either.

You might want to take a very close look at exactly why you are doing this
and what you hope to achieve (user wants to log off in the middle of a job
and resume in the morning?) and make sure you can get the locks to the
appropriate records again if you need them.

Also, what if this user is modifying a customer record, but unbeknownst to
them someone else went ahead and made other changes.  There is the very good
potential to stomp over another user's work.  This may or may not apply, I
don't know what you are trying to accomplish.

Regards,

Jim Langston
Programmer/Analyst
Cels Enterprises, Inc.

-----Original Message-----
From: owner-mi400@midrange.com [mailto:owner-mi400@midrange.com]On
Behalf Of Rohn.Blake@helpsystems.com
Sent: Wednesday, August 08, 2001 2:49 PM
To: MI400@midrange.com
Subject: Saving program variables?



...for what seems like (believe it or not) a simpler design approach, I
want to save all the values of all the variables in my RPG to a user
space/index. And later... on future calls to the program I want to retrieve
those values and repopulate all the variables (including variables which
are field names from database files - repositioning the files for READE is
not necessary, unless equally simple). *INLR will likely not be set on
between calls, if it makes a difference.


It seems to me like this should be quite doable and quite simply done...
just grab that portion of "memory" and stash it away.


Any thoughts or advice on direction?

Thanks!
Rohn

+---
| This is the MI Programmers Mailing List!
| To submit a new message, send your mail to MI400@midrange.com.
| To subscribe to this list send email to MI400-SUB@midrange.com.
| To unsubscribe from this list send email to MI400-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: dr2@cssas400.com
+---

+---
| This is the MI Programmers Mailing List!
| To submit a new message, send your mail to MI400@midrange.com.
| To subscribe to this list send email to MI400-SUB@midrange.com.
| To unsubscribe from this list send email to MI400-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: dr2@cssas400.com
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.