[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: header foolishness



Clark,
   First of all it's difficult to determine what's happening using only
the heading section... How you manage your page-breaks will determine
the proper heading variables... "First-Time" logic typically isn't
contained in a heading routine... SQR buffers it's output before
printing headings/footings so the mainline logic would be helpful...
Also, You're using $old_vendor_id but not $old_vender_INFORMATION...
there's a discrepency in the logic... Also, You're testing $last_page
and $letter both for a value of 'N'... I don't see $letter being reset
within this condition yet $letter is tested for 'Y' within this contruct
in order to print sub_heading - It's not going to happen unless you
assign it within the main "if"... In short... Control-Break processing
is very basic... For it to be effective you should keep it "basic"...
There's too many switches ($first_time, $last_page) that are unnecessary
and the "break" logic needs to be handled outside of the heading area...
If you post the mainline logic it would be easy to determine the
problem...

                               -Tony DeLia



C. Willis III wrote:
>
> Don,
>
> Your reply makes sense, but why would I get the correct values in the
> show statements below in the begin-heading, and then get different (the
> next record's) value when it actually prints??
>
> Begin-Heading 15
>
> do supra_heading
>
> show 'last page flag = ' $last_page
>
> if $last_page = 'N' and $letter = 'N'
>
>   if $first_one = 'Y'
>     show 'first vendor'
>     show $vendor_id
>   else
>     show 'not first'
>     show 'vendor = ' $old_vendor_id
>   end-if
>
>   show 'vendor name = ' $vendor_name
>   show 'address one = ' $addr_one
>   show 'address two = ' $addr_two
>   show 'address thr = ' $addr_thr
>   show 'address for = ' $addr_for
>   show 'vendor city = ' $city
>   show 'vendr state = ' $state
>   show 'vendor post = ' $postal
>
>   print 'Vendor :'                            (+1,   3)
>   if $first_one = 'Y'
>     print $vendor_id                          ( 0,  13)
>   else
>     print $old_vendor_id                      ( 0,  13)
>   end-if
>
>   if $vendor_name <> ' '
>     print '  '                                ()
>     print $vendor_name                        ()
>   end-if
>
>   if $addr_one <> ' '
>     print $addr_one                           (+1,  13)
>   end-if
>
>   if $addr_two <> ' '
>     print $addr_two                           (+1,  13)
>   end-if
>
>   if $addr_thr <> ' '
>     print $addr_thr                           (+1,  13)
>   end-if
>
>   if $addr_for <> ' '
>     print $addr_for                           (+1,  13)
>   end-if
>
>   print $city                                 (+1,  13)
>   print ' '                                   ()
>   print $state                                ()
>   print ' '                                   ()
>   print $postal                               ()
>
>   show 'counter = ' #counter
>   show '$letter = ' $letter
>
>   if $letter = 'Y'
>     do sub_heading                                 ! proc 15
>   end-if
> end-if
>
> End-Heading
>
> bewildered in milwaukee,
> clark
>
> ----Original Message Follows----
>
> On Thu, 17 Dec 1998, C. Willis III wrote:
> > Report   Page    Header
> >   1       1        1  (correct)
> >   1       2        2  (Not)
> >   2       1        2
> >   2       2        3
> >   3       1        3
> >   3       2        4     etc.
>
> Sorry this is so late, but I hadn't noticed any other replies, so...
>
> Judging from this "example" I would guess that whatever values are being
> set for the header, are now being reset *before* the "new-page" for the
> report-break happens instead of after.  If that's not it, tell us more.
>
> HTH,
> ----------------------------------------------------------------------
> Donald Mellen  | Ray Ontko & Co. - Richmond, IN - http://www.ontko.com/
> donm@ontko.com |  "In the beginning, there was nothing, which exploded"
>
> ______________________________________________________
> Get Your Private, Free Email at http://www.hotmail.com

--
Tony DeLia
AnswerThink Consulting Group
PeopleSoft Solutions Practice - Delphi Partners
tdelia@erols.com