Home » Developer & Programmer » Forms » call a pdf report from a form
call a pdf report from a form [message #419411] Fri, 21 August 2009 23:14 Go to next message
charuamit
Messages: 121
Registered: January 2009
Senior Member
Hi friends

I want to generate a dynamic pdf report and call it in my form on button pressed....
I mean instead of calling a rdf file,i want to generate a pdf report and call it...

Any ideas ?
Thanks.
Charu
Re: call a pdf report from a form [message #419686 is a reply to message #419411] Tue, 25 August 2009 02:58 Go to previous messageGo to next message
RAY_HT
Messages: 153
Registered: May 2005
Location: Giza
Senior Member

use RUN_REPORT_OBJECT
Re: call a pdf report from a form [message #419941 is a reply to message #419411] Wed, 26 August 2009 04:41 Go to previous messageGo to next message
sharjeelshafqat
Messages: 33
Registered: August 2009
Location: Pakistan
Member

declare
repid REPORT_OBJECT;
v_rep VARCHAR2(100);
rep_status VARCHAR2(50);
BEGIN
repid := find_report_object(E:\Forms\report.rdf');
SET_REPORT_OBJECT_PROPERTY(repid,REPORT_EXECUTION_MODE,BATCH);
SET_REPORT_OBJECT_PROPERTY(repid,REPORT_COMM_MODE,SYNCHRONOUS);
SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESTYPE,CACHE);
SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESFORMAT,'pdf');
SET_REPORT_OBJECT_PROPERTY(repid,REPORT_SERVER,'rep_sharjeel');
SET_REPORT_OBJECT_PROPERTY(repid,REPORT_OTHER,'EMPNO='||:EMPNO||' paramform=no');
v_rep := RUN_REPORT_OBJECT(repid);

rep_status := REPORT_OBJECT_STATUS(v_rep);
WHILE rep_status in ('RUNNING','OPENING_REPORT','ENQUEUED')
LOOP
rep_status := report_object_status(v_rep);
END LOOP;
IF rep_status = 'FINISHED' THEN
WEB.SHOW_DOCUMENT('/reports/rwservlet/getjobid'||substr(v_rep,instr(v_rep,'_',-1)+1)||'?'||'server=rep_sharjeel','_blank');
ELSE
message('Error when running report');
END IF;
END;
Re: call a pdf report from a form [message #422907 is a reply to message #419941] Mon, 21 September 2009 02:48 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
You do NOT need to use 'run_report_object' before calling 'web.show_document'. Use the latter only and you will save yourself a world of pain.

David
Re: call a pdf report from a form [message #423650 is a reply to message #422907] Sat, 26 September 2009 00:03 Go to previous message
charuamit
Messages: 121
Registered: January 2009
Senior Member
Thxs for all your valuable suggestions

regards.
Charu
Previous Topic: Using Java beans on forms 6i
Next Topic: attache Pll Libraray
Goto Forum:
  


Current Time: Sat Dec 03 12:28:54 CST 2016

Total time taken to generate the page: 0.11639 seconds