Home » Developer & Programmer » Forms » Error while calling Report from Forms 10g
Error while calling Report from Forms 10g [message #254550] Fri, 27 July 2007 01:56 Go to next message
ShaShalini
Messages: 59
Registered: January 2007
Member
Hi All

I am trying to call a report from forms. I have been able to call the report in pdf format and it works fine. But my requirement is that the report should be printed directly .. And this gives me error. I am using forms 10g , application server is SUN Solaris Sparc 10.

I just get the error enable to run report .
The code is as follows

DECLARE
v_report_id Report_Object;
vc_ReportServerJob VARCHAR2(100);
vc_rep_status VARCHAR2(100);
vjob_id VARCHAR2(100);
choice number;
BEGIN
v_report_id := FIND_REPORT_OBJECT('REP_CMS');
SET_REPORT_OBJECT_PROPERTY(v_report_id,REPORT_COMM_MODE,SYNCHRONOUS);
SET_REPORT_OBJECT_PROPERTY(v_report_id,REPORT_DESTYPE,printer);
SET_REPORT_OBJECT_PROPERTY(v_report_id,REPORT_SERVER,'rep_sun6_Ora10gAS');

SET_REPORT_OBJECT_PROPERTY(v_report_id,REPORT_OTHER,
' paramform=no' ||' copies=1');

vc_ReportServerJob := RUN_REPORT_OBJECT(v_report_id);

vjob_id := substr(vc_ReportServerJob,length('rep_sun6_Ora10gAS')+2,length(vc_ReportServerJob));

vc_rep_status := REPORT_OBJECT_STATUS(vc_ReportServerJob);

IF vc_rep_status = 'FINISHED' THEN
ALERTS.STOP_ALERT ('Report Printed'||vc_rep_status,choice);
ELSE
ALERTS.STOP_ALERT ('Report failed with error message '||vc_rep_status,choice);

END IF;

END;
Re: Error while calling Report from Forms 10g [message #254559 is a reply to message #254550] Fri, 27 July 2007 02:27 Go to previous messageGo to next message
linlasj
Messages: 98
Registered: August 2005
Location: Linköping
Member
Hi,
I think that there should be some other parameter as well, consult the on-line help in Oracle Reports. I believe that you hvae to set DESTYPE and DESNAME, the latter being the printer name.


Best Regards,
Lars

[Updated on: Fri, 27 July 2007 02:27]

Report message to a moderator

Re: Error while calling Report from Forms 10g [message #254580 is a reply to message #254550] Fri, 27 July 2007 03:37 Go to previous messageGo to next message
ShaShalini
Messages: 59
Registered: January 2007
Member
Hi

I tried putting the printer and the port also using the DESNAME parameter .. but that also does not work..


Thanks
Re: Error while calling Report from Forms 10g [message #254634 is a reply to message #254580] Fri, 27 July 2007 05:47 Go to previous messageGo to next message
linlasj
Messages: 98
Registered: August 2005
Location: Linköping
Member
Hi,
OK. Please see to it that the Reports Services is awake.

That could be done using the URL
http://your.domain:port/reports/rwservlet

there you also find some useful commands, and you can hopefully study what was the error in more detail with the report.


Best Regards,
Lars
Re: Error while calling Report from Forms 10g [message #255176 is a reply to message #254550] Mon, 30 July 2007 23:36 Go to previous message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
I suggest that you use 'web.show_document'. Search this forum using this key word and you will find numerous working examples.

David
Previous Topic: Global Variable values for Triggers
Next Topic: How can I get a directory files in my form in ascending order by modify date
Goto Forum:
  


Current Time: Wed Dec 07 20:29:20 CST 2016

Total time taken to generate the page: 0.08928 seconds