Results 1 to 2 of 2

Thread: Grid Lines and errors

  1. #1
    Senior Member
    Join Date
    Oct 2000

    Grid Lines and errors

    I am having difficulty with a application I am writing. It is a header
    detail. The grid can be populated with many (several hunderd) records. The
    user can change data in one field (for example ship quantity). I want (and
    have) an error in the grid to indicate that the ship quantity is greater
    then the Order quantity. If any (just takes one) of the grid lines has this
    error then I want the form exits disabled.

    I first tired to the the system value "ERROR Status" but that only gets set
    to an error when business functions return a error, or a table IO fails, not
    when the set error system function is used. So it was no help. My second
    idea was to set a error flag (say ev01) in the "Grid section changed +
    exited - inline" to test for the error, and if present set the flag to "1",
    else "0". This worked until I had errors on multiple lines. THen as soon
    as I fixed one line, the error status became "0" (that controls the system
    function to enable the form exits). The only other thing I can think of is
    to read every record in the grid each time a grid row is exited. That just
    seems like a lot of reading just to see if one line has a problem. If I had
    100 grid lines and the user changed 50 of them, I would have to do 5000 grid
    line reads...

    Anyone have a better idea?

    B7332 sp 13.1 AS/400 v4r4

    __________________________________________________ _______
    Do You Yahoo!?
    Get your free address at

    OneWorld Xe SP22 AS/400 V5R2

  2. #2
    Senior Member Zoltan_Gyimesi's Avatar
    Join Date
    Oct 2000
    Budapest, Hungary

    Re: Grid Lines and errors

    Hi Aaron,

    Use the SetGridCellError / ClearGridCellError System Function pair (Grid category).
    The best events to use them are:
    * Column Exited
    * Column Exited and Changed - Inline
    * Column Exited and Changed - Asynch
    * Row Exited
    * Row Exited and Changed - Inline
    * Row Exited and Changed - Asynch

    All of these events have to be (surely will be) finished before OK processing. OK automatically won't work while just one Error exist although the OK button and OK menu selection won't be grayed out. Pressing OK just won't have any affect.

    If the compare value is also in a column and it is updatable then the best choices are the ROW events. It prevent to duplicate your Error setting logic on both fields.

    Hope, could help
    ... and let us know if you have further problem in this issue (or in an other one :-)


    B7332 SP11, ESU 4116422, Intel NT4, SQL 7 SP1
    (working with B7321, B7331, XE too)
    - XE UPDATE 2 SP22, Intel NT4, SQL 2000
    - B9 (8.93B1)
    - was/is working with B7321, B7331, B7332 too

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
The legal restrictions and terms of use applicable to this site are available here.
Use of this site signifies your agreement to the terms of use.
JDELIST is NOT affiliated with JD Edwards® & Company, Oracle or Peoplesoft. Contents of this site are neither endorsed nor approved by JD Edwards® & Company and, or Oracle.