Subject: | |
From: | |
Reply To: | Dr. Ferenc Nagy |
Date: | Thu, 23 Feb 1995 12:31:47 +0100 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
On Wed, 22 Feb 1995 R. C. Ready wrote:
> I have a VPLUS screen (ASRC3) on which fields C and D can have a value
> entered; in which case they should be automatically zero filled, right
> justified and in
> the range 000.0 to 300.0. (C and D are defined as length=5 and type=num1).
>
> If C and/or D are blank I want them to be set to 050.0 if field A
> (occurring before them on ASRC3) is = P other wise I want to set the
> field(s) to 100.0.
>
> I have defined a save field SAVEFEE; length=1 (same as A) and
> type=char(also, same as A). I have set the processing specification for A as
>
> SET SAVEFEE TO A
>
> I set the processing specification for C as
>
> SET TO C
> JUSTIFY RIGHT FILL LEADING "0" IN 000.0:300.0 "ERROR"
>
> and the right justify and zero fill with the range check worked fine.
>
> When I tried
>
> IF EQ $EMPTY THEN
> IF SAVEFEE EQ "P" THEN
> SET TO 050.0
> SET TO C (I tried this line, although i am not sure I need it)
> ELSE
> SET TO 100.0
> SET TO C
>
> IF NE $EMPTY THEN
> JUSTIFY RIGHT FILL LEADING "0"
> IN 000.0:300.0 "ERROR" (****)
>
> C is not calculated, if blank and the zero fill doesn't work.
>
> If I have a SET TO C as the first line the zero fill, right justify and
> decimal allignment is ok.
>
> If I have a SET TO C after the line marked with (****) the zero fill
> doesn't work either.
>
> One of the things I am not clear about is the positioning of the SET
> command.
>
> Any help would be greatly appreciated.
Romilla,
if the type of the field is Optional then the processing statements are
NOT executed.
Change the field type to Processed.
Frank
************************Family : NAGY
*NNN......NN..FFFFFFFFF*First name : FERENC
*NNNN.....NN..FFFFFFFFF*Title : Ph. D., Scientific Co-Worker
*NN.NN....NN..FF.......*Company : Institute of Isotopes of
*NN..NN...NN..FF.......* the Hungarian Academy of Sciences
*NN...NN..NN..FFFFFF...*E-mail : [log in to unmask]
*NN...NN..NN..FFFFFF...* : [log in to unmask]
*NN....NN.NN..FF.......*P.O.B. addr.: 1525 BUDAPEST Pf. 77., HUNGARY
*NN....NN.NN..FF.......*Street addr.: 1121 BUDAPEST Konkoly-Thege M. ut 29.
*NN.....NNNN..FF.......*Fax : (36)-1-156-5045 or try (36)-1-169-5087
*NN......NNN..FF.......*Phone : (36)-1-275-4351 <=== NEW!
*NN......NNN..FF.......*Home address: 1214 BUDAPEST Raketa u. 29. I. 3., HUNGARY
************************Home phone : (36)-1-277-4229
"There are three kinds of programming errors: syntactical, semantical and
mystical."
"The programmers have to suck up the users just as much as absolutely
necessary."
|
|
|