Odd things happening...
John Esak
john at valar.com
Wed Mar 2 13:37:09 PST 2005
<top posted... sorry>
Might as well add my 2 cents to this thread... Everybody is talking about
INPUT processing and how it relates to clearing the non global dummies.
Actually, I have always thought that the non-global dummies are cleared at
the very top of the automatic table. The clearing process has nothing to do
with INPUT really... (Ken can verify this). Every time the top of the AUTO
table is hit (let's call it line 0) non global dummies get cleared. So,
along with your lookup - note, there are several other places where they
will clear that you might not expect, most important to me is when you
execute an @key. The first thing to run is the AUTOMATIC table, so all non
global dummies are cleared. If you need to do anything @entsel based on the
push of an @key, you need to use a global dummy. the main way I run
everything at @entsel (so the record isn't being locked during the
operation) is as follows:
@keyT if:
then: declare runkey(1,,g); runkey="T"; end
@entsel if: runkey eq "T"
then: runkey=""; gosub do_keyT; end
do_keyT if:
then: 'some browse lookup to a detail file or whatever...
if:
then: return
Actually, my real code is more elaborate than this, but this shows the basic
idea. If the runkey variable was not declared global, this neat snippet
wouldn't work because the first thing that happens when you push an @key is
the automatic table runs.
John
> -----Original Message-----
> From: filepro-list-bounces at lists.celestial.com
> [mailto:filepro-list-bounces at lists.celestial.com]On Behalf Of Howie
> Sent: Wednesday, March 02, 2005 2:31 PM
> To: filepro-list at lists.celestial.com
> Subject: Re: Odd things happening...
>
>
>
> ----- Original Message -----
> From: "Nancy Palmquist" <nlp at vss3.com>
> To: <filepro-list at lists.celestial.com>
> Sent: Wednesday, March 02, 2005 1:52 PM
> Subject: Re: Odd things happening...
>
>
> | Kenneth Brody wrote:
> |
> | > Quoting Jeff Harrison (Wed, 2 Mar 2005 08:44:18 -0800 (PST)):
> | > [...]
> | >
> | >>2) As I understand it non-global dummy fields will
> | >>only hold their value for the duration of the
> | >>processing table in which they are set. If the
> | >>variable is assigned in input processing then as soon
> | >>as input processing is over then the value is lost -
> | >>even if the field was declared in the automatic table.
> |
>
> To add to Nancy's list: non global dummy variables will be cleared if you
> use the "lookup -" command too.
>
> Howie
>
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> http://mailman.celestial.com/mailman/listinfo/filepro-list
More information about the Filepro-list
mailing list