saving report in client's machine [message #424660] |
Mon, 05 October 2009 03:59 |
sd_md_rizwan@yahoo.com
Messages: 37 Registered: September 2007 Location: Saudi Arabia
|
Member |
|
|
Hi this is Rizwan,
I am using
Windows 2003 Server with service pack 2,
Oracle Database 10.1.2.0.2
Oracle Developer 10.1.2.0.2
Webutil_106
I have a form which is running on the web and calling PDF reports with buttons one is for opening the report and the other for saving reports, when I open my form in a client pc I am able to open the PDF report by clicking the open button but when I click the save button it is not saving the report in client pc, the need of that button is to save the multiple reports at same time in client's pc, In my form I am also creating the directory
in client's pc using client_host command and also I am able to open that directory
this is my code
DECLARE
V_REPORT VARCHAR2(100);
PL_ID PARAMLIST;
VPATH VARCHAR2(100);
BEGIN
RMDIR;
MKDIR;
FOR MN IN (SELECT DISTINCT BR_NUM,SEX_CODE FROM EMP_FILE_DETAILS
WHERE MNTH_CODE = :CONT_BLOCK.MNTH_CODE
AND AREA_CODE = :CONT_BLOCK.AREA_CODE AND BR_NUM IN (1,2,3,4)
ORDER BY BR_NUM,SEX_CODE)
LOOP
PL_ID := GET_PARAMETER_LIST('TEMPDATA');
IF NOT ID_NULL(PL_ID) THEN
DESTROY_PARAMETER_LIST(PL_ID);
END IF;
PL_ID := CREATE_PARAMETER_LIST('TEMPDATA');
SET_REPORT_OBJECT_PROPERTY('NEW_MN_REP',REPORT_DESNAME,'C:\QUALITY_REPORTS\REP_OF_'||:CONT_BLOCK.MNTH_CODE||'-'||MN.BR_NUM||'-'||MN.S EX_CODE||'.PDF');
ADD_PARAMETER(PL_ID,'PMNTH_CODE',TEXT_PARAMETER,:CONT_BLOCK.MNTH_CODE);
ADD_PARAMETER(PL_ID,'PBR_NUM',TEXT_PARAMETER,MN.BR_NUM);
ADD_PARAMETER(PL_ID,'PSEX_CODE',TEXT_PARAMETER,MN.SEX_CODE);
V_REPORT := RUN_REPORT_OBJECT('NEW_MN_REP',PL_ID);
:CONT_BLOCK.STATUS := ('MNTH_CODE = '||:CONT_BLOCK.MNTH_CODE||' -BR_NUM = '||MN.BR_NUM||' - SEX_CODE = '||MN.SEX_CODE);
SYNCHRONIZE;
END LOOP;
OPEN_DIR;
END;
I think I need to change something in this line
SET_REPORT_OBJECT_PROPERTY('NEW_MN_REP',REPORT_DESNAME,'C:\QUALITY_REPORTS\REP_OF_'||:CONT_BLOCK.MNTH_CODE||'-'||MN.BR_NUM||'-'||MN.S EX_CODE||'.PDF');
To get the client pc's path
Can anybody help me out of this as soon as possible
Thanks.
|
|
|
|
|
|
|
|
Re: saving report in client's machine [message #429997 is a reply to message #424660] |
Fri, 06 November 2009 14:26 |
dlwixon
Messages: 92 Registered: September 2008
|
Member |
|
|
1) Use web.show_document() to write the report to the app server
2) Use webutil_file_transfer.is_as_readable to make sure the report is readable
3) If the report is readable then use webutil_file_transfer.as_to_client to transfer the report from the app server to the client machine.
[Updated on: Fri, 06 November 2009 15:18] Report message to a moderator
|
|
|