Focal Point
PDF with REPEAT

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/6301079181

August 23, 2006, 10:13 AM
neuro
PDF with REPEAT
Can anyone tell me how to create a PDF statement before a REPEAT that will open the PDF like:

ON GRAPH PCHOLD FORMAT PDF OPEN


And then after the ENDREPEAT CLOSE it by the following:


ON GRAPH PCHOLD FORMAT PDF CLOSE


Do I have to do this within the REPEAT by doing a CASE/IF or can this be done outside of the REPEAT.


Currenly working @ Learning Circle Education Services
Previously worked @ Nationwide Insurance
Prod: WebFOCUS 7.6.11


Test: WebFOCUS 7.6.11


Dev: WebFOCUS 7.6.11
August 23, 2006, 11:08 AM
Tony A
neuro,

Try something like this as I have found the SET COMPOUND = OPEN / CLOSE problematic at best in 7.1.3!

SET HOLDLIST = PRINTONLY
TABLE FILE CAR
BY COUNTRY
ON TABLE SAVE
END
-RUN
-SET &Loops = &LINES;
-SET &Cnt = 1;
-READ SAVE, &Country&Cnt.EVAL
-REPEAT :Loop WHILE &IORETURN EQ 0;
-SET &Cnt = &Cnt + 1;
-READ SAVE, &Country&Cnt.EVAL
-:Loop

-SET &Cnt = 1;
-REPEAT :Loop2 &LINES TIMES;
-SET &Compound = IF &Cnt EQ 1 THEN 'OPEN NOBREAK' ELSE IF &Cnt EQ &Loops THEN 'CLOSE' ELSE 'NOBREAK';
TABLE FILE CAR
SUM RCOST
    DCOST
 BY CAR
 BY MODEL
 WHERE COUNTRY EQ '&Country&Cnt.EVAL'
ON TABLE PCHOLD FORMAT PDF &Compound
END
-SET &Cnt = &Cnt + 1;
-:Loop2


T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
August 23, 2006, 02:35 PM
neuro
Awesome, it worked for your CAR example, but after modifying it a bit I was able to get it to work for my code!

Many thanks!


Currenly working @ Learning Circle Education Services
Previously worked @ Nationwide Insurance
Prod: WebFOCUS 7.6.11


Test: WebFOCUS 7.6.11


Dev: WebFOCUS 7.6.11
August 23, 2006, 06:39 PM
Tony A
neuro,

You are most welcome, glad it helped you out!

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10