Jump to content

I am trying to populate data into multiple sheets using exce...


Subbarao Desu

Recommended Posts

I am trying to populate data into multiple sheets using excel template option. when I am populating data into single sheet things are working fine but when populating to multiple sheets it is giving the below error.

(FOC1522) ntjprerr: CALLPGM execution error caused by:

(FOC1522) java.util.zip.ZipException: duplicate entry:

(FOC1522) xl/worksheets/sheet2.xml. CPJAVA: Error in processing EXECUTE

(FOC1522) command for Class ibi.jsexcel.JscomExcelZip

Here is the sample code I used. We are on 8202.

TABLE FILE CAR

PRINT *

ON TABLE SET BYDISPLAY ON

ON TABLE PCHOLD AS CARSAMPLE FORMAT XLSX TEMPLATE carsamplenew.xltx SHEETNUMBER 2 OPEN

END

TABLE FILE GGSALES

PRINT *

ON TABLE SET BYDISPLAY ON

ON TABLE PCHOLD AS CARSAMPLE FORMAT XLSX TEMPLATE carsamplenew.xltx SHEETNUMBER 3 CLOSE

END

Appreciate any insights on this if anyone faced it earlier.

Thanks,

Subbu.

Link to comment
Share on other sites

Your template file has to have as many sheets as your are going to populate. Then then "ON TABLE PCHOLD commands should look like this:

APP PATH ibisamp

TABLE FILE CAR

PRINT COUNTRY CAR

ON TABLE HOLD AS SHEET1 FORMAT XLSX TEMPLATE book1.xltx SHEETNUMBER 1

END

-RUN

TABLE FILE CAR

PRINT CAR MODEL

ON TABLE HOLD AS SHEET2 FORMAT XLSX TEMPLATE sheet1.xlsx SHEETNUMBER 2

END

-RUN

TABLE FILE CAR

PRINT MODEL SEG.BODYTYPE

ON TABLE PCHOLD FORMAT XLSX TEMPLATE sheet2.xlsx SHEETNUMBER 3

END

-RUN

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...