Save BI Publisher Report Generated as PDF as Attachment Using eScript

(Doc ID 1063303.1)

Last updated on MARCH 02, 2017

Applies to:

Siebel Reports, SPE - Version 7.8.2.10 SIA [19241] and later
Information in this document applies to any platform.
""Checked for Relevance on 10-FEB-2016""

Symptoms


When creating a new attachment in Siebel using the url to the BI Publisher report by using a button with eScript the following error is shown:


 

[1] Siebel eScript runtime error occurred in procedure 'InvokeMethod' of BusComp [Opportunity Attachment]:

Error: SiebelError: Generic Error in Compression Routine(SBL-UIF-00227)

(SBL-SCR-00141)
[2] Stack trace:
BusComp [Opportunity Attachment].InvokeMethod(), Built-in function
BusComp [Opportunity Attachment].BusComp_PreInvokeMethod(), Line: 8

The code is:

switch(MethodName){
case 'CreateReport':
var RetValue;
var fileBC;
this.NewRecord(NewAfter);
RetValue = this.InvokeMethod("CreateFile", "http://xxx123:9704/xmlpserver/Test 2/Guest/Guest.xdo?_xpf=&_xpt=1&_xdo=%2FTest%202%2FGuest%2FGuest.xdo&AccNameSpec=IRIS&AccountId=&_xt=New%20Template%202&_xf=pdf&_xmode=4", "OpptyFileName", "Y");
this.WriteRecord();
return (CancelOperation);
break;


Using the same code but specify a file from the local pc (eg. RetValue = this.InvokeMethod("CreateFile", "c:\\report.pdf", "OpptyFileName", "Y"); instead of the url, the attachment is created correctly.

This works if using the 'new file' button and paste the url in the 'Filename' field to select the file. The output PDF report is correctly stored on the Siebel file system.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms