You are viewing this site as a guest. You can still ask questions and help others! Join our Dev2Dev IT Community to receive your own blog, share your knowledge, and much more.

Insert logo to CSV report using SQR

1 reply [Last post]
Guest's picture


Do u have any idea on how to print image as logo to the header of a CSV report?

I have searched for the codes but only found code to print image to PDF file.

Appreciate your help. Thanks.

Lepa's picture
User offline. Last seen 2 years 20 weeks ago. Offline
Joined: 06/23/2008
Posts: 591
Re: Insert logo to CSV report using SQR

I found case# 1147733.1 logged in on peoplesoft support site. Below is their recommedation on how To Print An Image/Logo When Using SQR programs. I never had the need to do such a requirement so hope it helps anyway!

You can place logos and other images in a report by using only the PRINT-IMAGE command. However, the DECLARE-IMAGE command is useful if you want several programs to share the definition of an image.

PeopleBooks describes a possible method and provides an example of how to do so. In addition, PeopleSoft provides a sample program called sqrlogo.sqr which you can review, and customize to your needs.

You can read more about this functionality in the related Bookshelf
PeopleBooks Library > PeopleTools 8.4x: SQR for PeopleSoft Language Reference – “SQR Samples” section

NOTE: SQR Samples is a library of SQR programs that you can use to modify and experiment with programs. These programs are stored in the \bin\sqr\\SAMPLE, (SAMPLEW for Microsoft Windows), directory. You can modify these programs to create configured SQRs.

Please look for the SQR Sample program, (“sqrlogo.sqr”, “emp.sqr”, “emp_comm.sqr”), that can be found in the folder \bin\sqr\\SAMPLE.

In order to print an image/logo perform the following steps:

1. Copy the “sqribe.eps” and “sqrlogo.sqr” under c:\temp location on Windows operating system.

2. Copy the “sqrlogo.sqr” program file from %PS_HOME%\bin\sqr\\\SAMPLEW to SQR folder(Location: %PS_HOME%\sqr).

3. Run the sqrlogo.sqr from the Process Scheduler.

4. Add the SQRLOGO.SQR to the SQR processes.
In order to add the new SQR process navigate to PIA:
People Tools > Process Scheduler > Processes
4.1. Press on the Add a New Value hyperlink.
4.2. Select SQR Report as Process Type and type SQRLOGO as Process Name.
4.3. Click on Add button.
4.4. Access Process Definition Options tab.
4.5. Under Process Security section Select PRCSMULTI as Component and TLSALL as Process Groups.
4.6. Save.

5. Use PIA navigation in order to run the SQRLOGO Report:
People Tools > Process Scheduler > System Process Requests.
5.1. Select an existing Run Cntrl ID or add a new one.
5.2. Select Run button.
5.3. Select the check box of the SQRLOGO SQR Report.
5.4. Specify Printer as Type and PS as Format.
5.5. In the output destination specify the \\computer name\printer name.
5.6. Click Ok button.
5.7. Check the Run Status, (Success), and Distribution Status, (Posted).
5.8. Check the physical printer and look for the output file printed.

NOTE: The *.bmp or *.jpg file could be used instead of *.eps file.

In the sqrlogo.sqr provided there should be changed the following two lines of code:
Source = 'c:\temp\sqribe.eps' –>> replace with a bmp image, (e.g. test.bmp that should be found under c:\temp location)
Type = EPS-FILE ->> replace with BMP-FILE

The sample program provided in the example above has been provided for test purposes.

Additional information can be found in People Books regarding the developing of particular SQR programs to print images:
PeopleBooks > Enterprise PeopleTools 8.4x PeopleBook: SQR for PeopleSoft Developers > Using Graphics - "Sharing Images Among Reports " section.

For instance the ex12c.sqr program prints a simple form letter.

Give back to the community and help it grow!
* Help with unanswered forum questions and issues
* Register or login to share your knowledge at your own blog