Code Comments
Programming Forum and web based access to our favorite programming groups.I have the following problem that I do not seem to be able to fix. The source code (see attachment line 200) has the line; 01 NFLD REDEFINES AFLD PIC Z(4).99-. When the program runs it gives an illegal value in NFLD when it executes the line 2348; MOVE NFLD TO PAID PAID is defined as (line 75); 77 PAID PIC S9(6)V99. It seems that the REDEFINES clause used in this manner with PIC will require the MF directive? Not sure where to place the directive and what syntax is required. We tried DIRECTIVE(MF) in the project options, but still get the same error. We also tried DIRECTIVE(MF) in the single compile options under tools, but still no luck. Any advice or ideas? Thanks Mark
Post Follow-up to this message>> I have the following problem that I do not seem to be able to fix. In general, it is not best practice to move an editted field to a data field.
Post Follow-up to this messageHeyBub wrote: > > > In general, it is not best practice to move an editted field to a data > field. > > Problem is that program is a migration and needs to stay as close to original as possible.
Post Follow-up to this message> 1) Please do NOT try to send attachments to newsgroups If it is such bad etiquete then why did you _repost_ it in its entirity.
Post Follow-up to this message> 1) Please do NOT try to send attachments to newsgroups If it is such bad etiquete then why did you _repost_ it in its entirity.
Post Follow-up to this messageGeez, you didn't have to post the whole program for one tiny point. > 01 NFLD REDEFINES AFLD PIC Z(4).99-. > MOVE NFLD TO PAID > 77 PAID PIC S9(6)V99. What you are trying to do is a de-editing move. In ANS'85 this is allowed as long as the data is aligned correctly in the picture. Aligned means that the data must be as if a move to the edited numeric field had been done, the full stop and the sign being in the correct position. MicroFocus has always allowed non-standard unaligned de-editing moves, but recently (last 20 years) this has depended on having the correct directives set when compiling. The actual directive is: DE-EDIT"1" Directives can be put on the compile command line or added to the directive file if you are using one or, in most cases, as a $SET at the start of your source code. However, you should be using: COMPUTE PAID = FUNCTION NUMVAL(AFLD)
Post Follow-up to this messageSorry, I did NOT realize that my "reply group" included the attachment (or I would NOT have done so) -- Bill Klein wmklein <at> ix.netcom.com "Richard" <riplin@Azonic.co.nz> wrote in message news:1115234040.376854.305620@g14g2000cwa.googlegroups.com... > > If it is such bad etiquete then why did you _repost_ it in its > entirity. >
Post Follow-up to this messageWilliam M. Klein wrote: > Sorry, I did NOT realize that my "reply group" included the attachment (or I > would NOT have done so) > Damned mice. Donald ;< )
Post Follow-up to this messageThanks Richard I will try this and post back if it worked. Mark Richard wrote: > Geez, you didn't have to post the whole program for one tiny point. > > > > > What you are trying to do is a de-editing move. In ANS'85 this is > allowed as long as the data is aligned correctly in the picture. > Aligned means that the data must be as if a move to the edited numeric > field had been done, the full stop and the sign being in the correct > position. > > MicroFocus has always allowed non-standard unaligned de-editing moves, > but recently (last 20 years) this has depended on having the correct > directives set when compiling. The actual directive is: > > DE-EDIT"1" > > Directives can be put on the compile command line or added to the > directive file if you are using one or, in most cases, as a $SET at the > start of your source code. > > However, you should be using: > > COMPUTE PAID = FUNCTION NUMVAL(AFLD) >
Post Follow-up to this messageJust so you know, I would NOT have bothered "editing" the post if it include d the entire text of the program (as one reply did). So, to that extent, my "usual top poster and does not edit" rules apply. I, however, do NOT like "attachments" because of virus issues (and/or formatting issues). -- Bill Klein wmklein <at> ix.netcom.com "Richard" <riplin@Azonic.co.nz> wrote in message news:1115238752.032565.282710@o13g2000cwo.googlegroups.com... > > Thank you for that, but that is, in fact, one of the reasons that > top-posters are disliked. They simply put a few lines at the top and > then send the whole thing off without even bothering to check, let > alone attempting to show relevence by trimming back to the actual lines > they are replying to. >
Post Follow-up to this messagePowered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.