ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Readc and SFLNXTCHG... PLEASE.....

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Readc and SFLNXTCHG... PLEASE.....

    Before I jump to my death... Can someone tell me what I need to change..

    I have a subfile, the user enteres data, I recalculate stuff... The first time they change the record it works fine. I change it again and it doesn't do the changes.

    I have...

    38 SFLNXTCHG specified on my SFL
    I load some blank records at the end of the subfile so I turn 38 off when I write those.

    I use readc with and indicator of 87.

    I want the readc to work everytime the record is changed.

    I haven't done this old stuff in a while. Can somebody wake my brain up and tell me what I'm missing here.. Thanks!

  • #2
    Re: Readc and SFLNXTCHG... PLEASE.....

    I never do ReadC. I just Read the subfile top to bottom and compare to hidden fields. I hate indicators will my passion.
    But for you, id start debug and see what indicators are poping when you change a value and when you add a line.
    Hunting down the future ms. Ex DeadManWalks. *certain restrictions apply

    Comment


    • #3
      Re: Readc and SFLNXTCHG... PLEASE.....

      I agree -- readc should only be allowed in CL programs.......

      you have to mess around with 87 (turn off)
      when reading thru updating the subfile.
      then back on prior to exfmt.

      I hope this helps a bit.
      All my answers were extracted from the "Big Dummy's Guide to the As400"
      and I take no responsibility for any of them.

      www.code400.com

      Comment


      • #4
        Re: Readc and SFLNXTCHG... PLEASE.....

        I always used readc, occasionally falling into a hole like this, but never falling back on reading the entire subfile

        but every situation being different, would have to see the code to find the problem

        Comment


        • #5
          Re: Readc and SFLNXTCHG... PLEASE.....

          The READC will always work when the record is changed. The SFLNXTCHG is only needed if you want the READC to pick the record up if it wasnt changed.
          Michael Catalani
          IS Director, eCommerce & Web Development
          Acceptance Insurance Corporation
          www.AcceptanceInsurance.com
          www.ProvatoSys.com

          Comment

          Working...
          X