Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

ORARRP and WebForms (Forms/Reports 9i/10g)

Posted on 2004-10-04
3
Medium Priority
?
6,004 Views
Last Modified: 2008-01-09
Hello,

I am deploying my Forms/Reports 9i application on a Linux Red Hat Server Enterprise 3 (ES) running FOrms/Reports Services 10g. My application uses and attached library called RP2PRO.PLL that contains a number of functions related to printer set-up. The RP2PRO.PLL attached library makes extensive reference to ORARRP.

I have read however that the following functions are no longer supportted under Oracle 9i iDS/iAS:
1) default.use_orarrp
2) default.orarrp_virtual_directory
3) default.orarrp_physical_directory

1) Can I still use the ORARRP Utility to print locally my Reports over the Web ?
(if not how could I go about this )

Your toughts ...

PT

0
Comment
Question by:ptreves
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 22

Accepted Solution

by:
Helena Marková earned 2000 total points
ID: 12225091
Where have you read it ? I have searched Metalink and I have not found such information.
There is Note: 277431.1 - How to Implement ORARRP with Forms & Reports 9i /10g for Local Printing on Client - (last modified 03-AUG-2004) there:

The information in this article applies to:
Oracle Reports Developer - Version: 9.0.2
Oracle Forms - Version: 9.0.2
Information in this document applies to any platform.
RUN_REPORT_OBJECT
ORARRP 1.3.4 (Oracle Reports Remote Printing Utility)
Goal
How to Implement ORARRP with Forms & Reports 9i /10g for Local Printing on Client?

ORARRP (Oracle Reports Remote Printing Utility) can be downloaded from the OTN website
Reference:

http://otn.oracle.com/sample_code/products/reports/index.html

The PDF document contained within the orarrp_1_3_4.zip file has instructions which appear specific to implementation of ORARRP in an Oracle 9iAS Rel 1 environment. This article aims to provide revised instructions for the implementation of ORARRP in a Oracle 9iAS Rel 2 or Oracle Application Server 10g environment

Fix
Follow the advice below in conjunction with the step by step instructions given in the ORARRP pdf document - orarrp1.3.4.pdf entitled 'Oracle Reports Remote Printing Utility - 1.3.4'

1. Add the required ORARRP mimetypes to the Oracle HTTP Server configuration.
(Note: This will be the Oracle HTTP Server belonging to the Oracle 9iAS Rel 2 / Oracle Application Server 10g middle (BI & Forms) tier)

Do this manually by editing the httpd.conf
or
via the Oracle 9iAS Rel 2 EM console / Oracle Application Server 10g AS Console e.g.
Navigate to the Middle Tier Components Page
Click on HTTP_Server -> Administration -> MIME Types

2. Create an aliasmatch in forms90.conf pointing to a physical directory - for this example, directory will be an example test area.
Do this by manually editing the forms90.conf
or
via the Oracle 9iAS Rel 2 EM console / Oracle Application Server 10g AS Console e.g.
Navigate to the Middle Tier Components Page
Click on HTTP_Server -> Administration -> Advanced Server Properties -> forms90.conf

Add a line like :

AliasMatch ^/forms90/test_area/(..*) "D:\test_area/$1"

** IMPORTANT NOTE **

The advantages of making the changes via EM / AS console, rather than editing the files manually, are:

- the EM / AS console will put the mimetype entries in the correct place
- the EM / AS console automatically issues a 'dcmctl updateconfig' which synchronises the file changes with the Infrastructure Metadata Repository
- the EM / AS console will do the required restart of the HTTP Server component

(Only the HTTP Server needs to be stopped and restarted - other 9iAS Rel 2 / OracleAS 10g components can remain up and running)

If the changes are made manually then the following commands must be issued after the changes to httpd.conf and forms90.conf have been made.

$ORACLE_HOME/dcm/bin/dcmctl updateconfig -ct ohs -v -d

(to synchronise the changes with the Metadata Repository)

$ORACLE_HOME/dcm/bin/dcmctl stop -ct ohs -v -d
$ORACLE_HOME/dcm/bin/dcmctl start -ct ohs -v -d

(to stop and restart the HTTP Server)

3. Install ORARRP.exe on the client machine as per instructions in the ORARRP pdf document

4. Check that ORARRP is basically working
- create orarrp_test.html containing the HTML

<html>
<body>
ORARRP Test! Click here to Print:
<a href="orarrp_test.rrpa">Acrobat Doc</a>
</body>
</html>

- Make a copy of the ORARRP pdf document and name it orarrp_test.rrpa

- Call it directly using a URL like:

http://[machinename.domain:portno]/forms90/test_area/orarrp_test.html

Click on the link - the Acrobat Reader should fire up with a print dialogue

5. Next create a test form containing the RUN_REPORT_OBJECT code (based on the advice in the ORARRP documentation

WHEN-BUTTON-PRESSED trigger
~~~~~~~~~~~~~~~~~~~~~
DECLARE
report_id REPORT_OBJECT;
hTimer TIMER;
vcFile VARCHAR2(255);
vcResult VARCHAR2(30);
BEGIN
/* Generate a pseudo unique filename */

vcFile := GET_APPLICATION_PROPERTY(USERNAME)||TO_CHAR(SYSDATE,'YYYYMMDDHHMISS');

/* In this example - output will be PDF so adding .rrpa extension */

vcFile := vcFile||'.rrpa';

report_id := find_report_object('TEST_ORARRP_REP');

SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESTYPE,FILE);

/* For DESNAME the physical directory on the middle tier has to be specified */

SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESNAME,'d:\test_area\'||vcFile);

/* In this example - PDF format is chosen */

SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_DESFORMAT,'PDF');

/* Specify the name of the Report Server to be used */

SET_REPORT_OBJECT_PROPERTY(report_id,REPORT_SERVER,'rep_servername');

/* Save the report handle and vcFile to Globals as they are to be referenced in the WHEN-TIMER-EXPIRED trigger */

:GLOBAL.ReportHandle := RUN_REPORT_OBJECT(report_id);
:GLOBAL.PrintOutPut := vcFile;

/* A timer will be used to check whether the Report execution is finished. In this example, the timer will fire 4 times every minute */

hTimer := CREATE_TIMER ('PRINTER_QUEUE', '15000', REPEAT);

END;
~~~~~~~~~~~~~~~~~

WHEN_TIMER_EXPIRED trigger contains the code
~~~~~~~~~~~~~~~~~

DECLARE

vcStatus VARCHAR2(50);
vcTimerName VARCHAR2(30);
hTimer TIMER;
BEGIN
vcTimerName := GET_APPLICATION_PROPERTY(timer_name);

/* Check whether the report has executed */

IF vcTimerName = 'PRINTER_QUEUE' THEN
vcStatus := REPORT_OBJECT_STATUS(:Global.ReportHandle);
IF vcStatus in ('RUNNING', 'OPENING_REPORT', 'ENQUEUED')
THEN
null;
ELSIF vcStatus = 'FINISHED'
THEN

/* The report has been executed and output sent to file under the test area directory, now access it using WEB.SHOW_DOCUMENT */

WEB.SHOW_DOCUMENT('/forms90/test_area/'||:GLOBAL.PrintOutPut,'_blank');

/* Clean up the timer */

delete_timer(vcTimerName);
ELSE

/* The Report has failed to run for some reason, throw out a basic failure message */

message('The Report has failed');
delete_timer(vcTimerName);
END IF;
END IF;
END;

6. Run the form to test

NOTE: A print dialogue will always display to the end user when using ORARRP. This is unavoidable. The end user will have to process the print dialogue
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Working with Network Access Control Lists in Oracle 11g (part 2) Part 1: http://www.e-e.com/A_8429.html Previously, I introduced the basics of network ACL's including how to create, delete and modify entries to allow and deny access.  For many…
Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
This video shows how to recover a database from a user managed backup

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question