Unconfigured Ad Widget

Collapse

Announcement

Collapse
No announcement yet.

Subfile Processing

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

  • Subfile Processing

    The only thing that's there is the screen layout, tiki. That would say nothing about what is wrong. Needed would be the RPG code and screen DDS. rd

  • #2
    Subfile Processing

    tiki, Are you updating each record to apply the changes? See code below. Tom. PS: Please post your RPG code, too.

    Comment


    • #3
      Subfile Processing

      This is what happened. When I choose option 2, another screen overlayed the subfile at the bottom of the screen to display and update the record. If only one record is selected the program worked just fine. If I choose multiple record, only the last I/O field was updated in the subfile 'Opt' and 'Warehouse Name' See the screen. The value of this fields supposed to be blanks and 'Test Test Test'. But the Output field were all updated. Attached Code.

      myprogram.txt

      Comment


      • #4
        Subfile Processing

        Include your screen DDS so we can see how it's defined.

        Comment


        • #5
          Subfile Processing

          Way too many missing definitions for me to be able to help, but my general comments are: 1) subfile field names look like they start with capital W (Wopt, WPLANT, WXMITFLG), but 'Test Test Test' is going into xwhsnam. Either that is not the subfile warehouse name field or that is bad naming. 2) I am curious how exitscr gets set to exit the do loop in $Chgrtn. 3) You condition updating the subfile record with cmdkey=Enter, which I assume is some renamed DS feedback field, but if they don't hit enter, and return instead, you will not update the option field to clear the 2 (I assume @chg). You may not have a return function key enabled now but you will need one if you don't, and will need to update every time to at least clear the option field. 4) Your program comments say Wopt and xwhsnam are I/O, but your readc only does select on the Wopt field. A change to another I/O subfile field such as xwhsnam would also trigger readc, and the code would fall through to $Wrongo. 5) On an error to update subfile you call $Clrmsg, the same routine called just before you check cmdkey to update, rather than write a message indicating the I/O error. 6) You turn *IN60 off when you update the subfile. It would be semi-interesting to know what *IN60 is, for example whether you have it defined for SFLNXTCHG or the like. Thanks for posting what you could so far, tiki. Your description leads one to think that readc is going to the last subfile record changed, skipping over the other changes, but missing definitions and a further comment or two from you describing what is going on I'm sure will let someone here resolve it. rd

          Comment


          • #6
            Subfile Processing

            Hi Ralph, I still doest know what the problem here but I put all the program and its gonna work if installed and compiled. I believed the problem was overlaying the subfile record format. No problem if only one record is updated or deleted. Thanks again. TIKI

            TESTPGM.txt

            Comment


            • #7
              Subfile Processing

              And I also notice that when I add records on the second screen and write it to the subfile, the records do not show until I exited from the second screen and redisplay the subfile. I have this program before in V4.5 and I dont have any issues. I just dont want the user to press F6 everytime they do multiple entry.

              Comment


              • #8
                Subfile Processing

                Good listing, tiki. I would not have MDT with SFLNXTCHG, especially using the same indicator, which is also SETOF. (I had to say knowing what *IN60 does would be semi-interesting. It is more than semi in this code. I have never used SETOF in a DDS, or MDT in a subfile. rd

                Comment


                • #9
                  Subfile Processing

                  I have a records in a subfile that only update the last record when I do a readc and do a muliple update. Its really weird because when I debug the program it update the fields in subfile but when the subfile was displayed, only the last record was updated. Any help will be appreciated. TIA, TIKI

                  Comment


                  • #10
                    Subfile Processing

                    If I remember correctly, the use of MDT in a subfile is a holdover from System/38 days. It is not necessary, and most likely unwise, to use in this instance. Dave

                    Comment

                    Working...
                    X