use dummy field as part of the goto label
Jay R. Ashworth
jra at baylink.com
Tue May 6 08:53:38 PDT 2008
On Mon, May 05, 2008 at 11:07:15AM -0400, Walter Vaughan wrote:
> Dennis Malen wrote:
> >Within input processing, is it possible to use a dummy filed as part of the
> >name of the goto label, such as:
> >
> >zz="rab";goto rpt{zz
> >
> >How can I have filepro acknowledge the rpt{zz and goto rptrab? When I try to
> >save the processing filepro tells me that there is no label by that name.
> >Obviously this is a limitation of filepro . Is there any way around this
> >limitation?
> >
> >
> In Define Processing's help you will see this
> 4.5 GOSUB/GOTO OF Gosub/goto one of a list of labels.
>
> Syntax
> GOSUB (num_expr) OF label1, label2, ...
> GOTO (num_expr) OF label1, label2, ...
> where num_expr is the one-relative index into the list
> of labels, and label1,label2, ... are the labels.
>
> Notes:
> The parentheses around (num_expr) are required.
>
> Only the integral portion of num_expr is used. Any
> fractional portion is ignored. The number is not rounded.
To expand this answer, no, the argument to a GOTO or GOSUB cannot be a
variable's contents (that I know of). It must be a literal.
If the handling of this issue was first-class, then you might be able
to do:
zz=rpt{"rab"; goto (zz)
but I'm pretty sure you can't.
Cheers,
-- jra
--
Jay R. Ashworth Baylink jra at baylink.com
Designer The Things I Think RFC 2100
Ashworth & Associates http://baylink.pitas.com '87 e24
St Petersburg FL USA http://photo.imageinc.us +1 727 647 1274
Those who cast the vote decide nothing.
Those who count the vote decide everything.
-- (Joseph Stalin)
More information about the Filepro-list
mailing list