|
Michael Naughton wrote: > > and I have a display file MSI410FM with fields defined as follows: > > A DSPQ01 3A B 17 22 > A DSPQ02 3A B 17 32 > A DSPQ03 3A B 17 42 > A DSPQ04 3A B 17 52 > A DSPQ05 3A B 17 62 > A DSPQ06 3A B 17 72 > > and in my program I have : > D E DS ExtName(@MSI4 ) > D MQ S Like(MSIQ01) Dim(12) Based(PMQ) > > D DQ S Like(DSPQ01) Dim(6) Based(PDQ) > D HQ S Like(MSIQ01) Dim(12) > . . . . > > I did a quick experiment and discovered that if change the display field > size from 3A to 4A, it seems to work. I also tried putting in an > externally-described data structure for the display file MSI410FM, but the > compile choked on the indicators. > > Can anyone help me understand what is going wrong here and/or how to how > to fix it? Does it have something to do with 8-byte boundaries for pointer > addresses? Why does it only seem to affect the display file fields? > ... Mike, the reason it works with the disk file fields is that you have explicitly said in your source that you want the fields from that file to be contiguous in your program. (You did this with your externally-described DS.) But you haven't said you want your display file fields to be contiguous. (The way your program fields are laid out can't be predicted - changing the size from 3 to 4 might not work in the future.) Try adding this, to put the fields you need to be contiguous into a DS: D DS D DSPQ01 (no datatype stuff here, just the names) D DSPQ02 D DSPQ03 D DSPQ04 D DSPQ05 D DSPQ06
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.