Home » Developer & Programmer » Forms » Webutil problem (WebUtil Version 1.0.6)
Webutil problem [message #300389] Fri, 15 February 2008 04:56 Go to next message
tisekofti
Messages: 21
Registered: February 2008
Junior Member
i am currently using the webutil tool in order to be able to print a report automatically from web from a clients side.

This is the command i am curently using:

client_host('CMD /C rwrun report=C:\formsRepository\exe\test1.rdf destype=printer desformat=HTML desname=\\CentralSrv\hp2420N5TH USERID=username\password@DEVELOP');

the java console is the following:

Oracle JInitiator: Version 1.3.1.22
Using JRE version 1.3.1.22-internal Java HotSpot(TM) Client VM
User home directory = C:\Documents and Settings\u00575

----------------------------------------------------
c: clear console window
f: finalize objects on finalization queue
g: garbage collect
h: display this help message
l: dump classloader list
m: print memory usage
q: hide console
s: dump system properties
t: dump thread list
x: clear classloader cache
0-5: set trace level to <n>
----------------------------------------------------

RegisterWebUtil - Loading WebUtil Version 1.0.6

proxyHost=null

proxyPort=0

connectMode=HTTP, native.

Forms Applet version is : 10.1.2.0

2008-Feb-15 12:50:56.799 WUI[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.799 WUF[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.814 WUH[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.814 WUS[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.814 WUT[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.814 WUO[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.814 WUL[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.814 WUB[VBeanCommon.findLocalHost()] obtaining LocalHost info from InetAddress

2008-Feb-15 12:50:56.908 WUI[getProperty()] Getting property WUC_BEAN_VERSION

2008-Feb-15 12:50:56.939 WUT[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:56.939 WUT[setProperty()] Setting property WUC_GET_LOCAL_PROPERTY to syslib.jacob.dll

2008-Feb-15 12:50:56.939 WUT[getProperty()] Getting property WUC_GET_LOCAL_PROPERTY

2008-Feb-15 12:50:56.971 WUT[setProperty()] Setting property WUC_GET_LOCAL_PROPERTY to syslib.JNIsharedstubs.dll

2008-Feb-15 12:50:56.971 WUT[getProperty()] Getting property WUC_GET_LOCAL_PROPERTY

2008-Feb-15 12:50:57.02 WUT[setProperty()] Setting property WUC_GET_LOCAL_PROPERTY to syslib.d2kwut60.dll

2008-Feb-15 12:50:57.02 WUT[getProperty()] Getting property WUC_GET_LOCAL_PROPERTY

2008-Feb-15 12:50:57.33 WUB[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUL[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUO[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUS[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUH[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUF[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUI[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:57.33 WUI[setProperty()] Setting property WUC_SRV_LOGGING to 0

2008-Feb-15 12:50:58.111 WUH[setProperty()] Setting property WUH_EXECUTION_MODE to 0

2008-Feb-15 12:50:58.111 WUH[setProperty()] Setting property WUH_EXECUTE to CMD /C rwrun report=C:\formsRepository\exe\test1.rdf destype=printer desformat=HTML desname=\\CentralSrv\hp2420N5TH USERID=login\LOGIN@DEVELOP

2008-Feb-15 12:50:58.111 WUH[getProperty()] Getting property WUH_EXECUTE

2008-Feb-15 12:50:58.408 WUH[setProperty()] Setting property WUH_PROC_ID to 6

2008-Feb-15 12:50:58.408 WUH[getProperty()] Getting property WUH_RC

2008-Feb-15 12:50:58.439 WUH[setProperty()] Setting property WUH_CLEAR_PROC to 6

is there any other way to print a report automatically from web using webutil?
Re: Webutil problem [message #300714 is a reply to message #300389] Sun, 17 February 2008 22:49 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
What made you thing of using this type of command?

David
Re: Webutil problem [message #300721 is a reply to message #300714] Sun, 17 February 2008 23:11 Go to previous messageGo to next message
tisekofti
Messages: 21
Registered: February 2008
Junior Member
Is there another way to succed this? I am just trying to print a report automatically.

For preview i am using web.show_document and i managed to accomplished that.
Re: Webutil problem [message #300737 is a reply to message #300721] Sun, 17 February 2008 23:54 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Please post code.

David
Re: Webutil problem [message #300739 is a reply to message #300737] Mon, 18 February 2008 00:15 Go to previous messageGo to next message
tisekofti
Messages: 21
Registered: February 2008
Junior Member
This is the code that i am currently using to previw my reports and it works.

PROCEDURE run_report (v_report varchar2) IS

report_id report_object;
report_job_id varchar2(200);
rep_status varchar2(200);
JOB_NUMBER number;
v_server varchar2(500):= 'server';
v_port number := port;
v_desformat varchar2(30):='pdf';
v_pl_id PARAMLIST;
v_pl_name VARCHAR2(20) :='REPORT_PARAM_LIST';
al_id ALERT;
v_dummy NUMBER;

BEGIN

if v_report='test' THEN

IF Set_Up_Parameter_List = 0 THEN

report_id:=FIND_REPORT_OBJECT(v_report);

IF get_application_property(USER_INTERFACE) = 'WEB' THEN
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_EXECUTION_MODE, RUNTIME);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_COMM_MODE, ASYNCHRONOUS);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESTYPE, cache);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESFORMAT,v_desformat);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_SERVER,v_repserver);
ELSE
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_EXECUTION_MODE, RUNTIME);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_COMM_MODE, ASYNCHRONOUS);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESTYPE, SCREEN);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESFORMAT,v_desformat);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_SERVER,'');
END IF;

v_pl_id := get_parameter_list(v_pl_name);

--Find the report and then run it, passing the new parameter list to it.
IF get_application_property(USER_INTERFACE) = 'WEB' THEN
report_job_id:=RUN_REPORT_OBJECT(report_id, v_pl_id);
--debug_message('Report_job_id is'||report_job_id);
ELSE
Run_Product(REPORTS, --product name
v_report, --module name
ASYNCHRONOUS, --communication mode
RUNTIME, --execution mode
FILESYSTEM, --location
v_pl_id, --parameter list
null);
END IF;

-- Check to see if the report is going to be run against the web
IF get_application_property(USER_INTERFACE)='WEB' THEN
rep_status:=REPORT_OBJECT_STATUS(report_job_id);
--debug_message('Rep_status is '||rep_status);
-- Dynamically Set the Job Number
JOB_NUMBER := length(v_repserver) + 2;
WHILE rep_status in ('RUNNING','OPENING_REPORT','ENQUEUED', null)
LOOP
rep_status:=REPORT_OBJECT_STATUS(report_job_id);
END LOOP;
IF rep_status='FINISHED' THEN
Web.Show_Document('http://' || v_server || ':' || v_port ||'/reports/rwservlet/getjobid=' ||substr (report_job_id,JOB_NUMBER)||'?server='||v_repserver,'_blank');
ELSE
message('Report failed with error message '||rep_status);
END IF; -- end of checking report status
END IF; -- end of checking to see if report is running on web.
END IF; -- end of checking parameter list set up ok
END IF; -- REPORt

to print automatically i am changing the following parts

SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_EXECUTION_MODE, RUNTIME);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_COMM_MODE, SYNCHRONOUS);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESTYPE, PRINTER);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESFORMAT,v_desformat);
SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_SERVER,v_repserver);

Re: Webutil problem [message #300757 is a reply to message #300739] Mon, 18 February 2008 00:54 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Try simplifying your code so that it looks more like http://www.orafaq.com/forum/m/144539/67467/?srch=web.show_document#msg_144539

David
Re: Webutil problem [message #300770 is a reply to message #300389] Mon, 18 February 2008 01:11 Go to previous messageGo to next message
tisekofti
Messages: 21
Registered: February 2008
Junior Member
ok i will have a look at the code that you have suggested. Thank you for your help.

Do i have to change anything to print the report?
Re: Webutil problem [message #300776 is a reply to message #300389] Mon, 18 February 2008 01:45 Go to previous messageGo to next message
tisekofti
Messages: 21
Registered: February 2008
Junior Member
hey David thank you so much for your help.
I have used your code (i have modified it a bit) and now i am able to print automatically.
Re: Webutil problem [message #301275 is a reply to message #300776] Tue, 19 February 2008 23:18 Go to previous message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Please post your new code to http://www.orafaq.com/forum/mv/msg/97459/301090/67467/#msg_301090

David
Previous Topic: Master-detail relationship on 2 tabs : coordination problem
Next Topic: Auto number & Duplicate record restriction
Goto Forum:
  


Current Time: Mon Dec 05 19:31:09 CST 2016

Total time taken to generate the page: 0.11396 seconds