Solved

Oracle Forms (9i) -  Best way to display HTML code in the database (VARCHAR2 field) from Oracle Forms

Posted on 2006-07-13
6
1,062 Views
Last Modified: 2012-06-27
Following: I am sending automatically HTML Emails from an Oracle 9i database.
After each email is sent, the subject, email body (...) get saved within the database.

Now, using and in oracle forms, an administrator can access / display the emails bodies - but this is pure HTML code; since full of HTML tags, it is not that easily readable.

I would like to add a push button close to this text field, so that as soon as pressed, an additional browser window (Internet Explorer) pops up displays the HTML message (formated this time).
You may nevertheless recommend another application to display this HTML code (formated), you are very much welcome.
Thanks to let me know how... do you I have to go for webUtil ? Or older OLE package is sufficient ?

0
Comment
Question by:csi-consulting
6 Comments
 
LVL 14

Expert Comment

by:sathyagiri
ID: 17101098
You should be able to do this with OLE container object.
See this link
http://www.oracle.com/technology/products/forms/htdocs/webutil/howto_ole.html
0
 

Author Comment

by:csi-consulting
ID: 17103444
Thanks. In fact I saw this one already. But it is dealing with word which does not seem the write application to display some HTML formated code. I need something more generic. I come back to Internet Explorer;

I just saw this evening in the oracle forum (http://forums.oracle.com/forums/message.jspa?messageID=484539)
the following which seems to be a very good start.

-- Code ----------------------
declare
webhandle ole2.obj_type;
args OLE2.LIST_TYPE;
begin

webhandle := OLE2.CREATE_OBJ('InternetExplorer.APPLICATION');
--Open
OLE2.set_property(webhandle,'Visible','True');
args := OLE2.create_arglist;
OLE2.add_arg(args,'c:\test.htm');
OLE2.invoke(webhandle,'Navigate',args);
OLE2.destroy_arglist(args);
(...)
OLE2.release_obj(webhandle);
end;
-----------------------------------------

Question from my side:
1. I guess the file which is getting opened is on the client side ? I am not sure this is the right thing to do since I am depending on the existence of a specific path where I would save a temporary file.
2. is it really not possible to avoid creating a file upfront ? I would like to pass the content of the database field directly to the internet explorer browser / do you think feasible ? How ?
3. Once again, any recommendation regarding a generic HTML editor is welcome. The standard Oracle Forms are fine but of course not to display formated HTML code.

Thanks again for your support!
0
 
LVL 2

Expert Comment

by:KJlt
ID: 17106069
I think OLE is a wrong way for solving your problem. AFAIK in Forms 9i OLE was deprecated... Please someone correct me if I am wrong...

I think you will need some Java Bean in your Forms for transfering html content to client side. There is a standart procedure in Forms for opening browser window whith desirable url (don't as whitch i don't remember).

Unfortunately i am not working with Forms now. I have no installation, no documentation and no will to come back to Forms :) I tried to help you as i could...

0
 

Author Comment

by:csi-consulting
ID: 17106374
Thank you very much. You are referring to web.show_document I guess.
And I was stuck there when I saw 'SHOW_DOCUMENT (url, target);'
One question would be if in the worst case I can reference a file in the url instead of http:// ... but the problematic with the files I would like to avoid would remain / I preferred not to investigate further.

Preferably, would go for your solution with the Java Bean but must admit that I did not learn Java myself. More information / documentation on how to pass the html code to the client side would be great - a small example would be the best. Thanks again in any case.
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 19995477
PAQed with points refunded (500)

Computer101
EE Admin
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Pl/SQL Query 31 77
How to return an OUT parameter from and ORACLE 3 57
SQL Retrieve Values 4 57
Web Service from a stored procdure oracle 10 49
Note: this article covers simple compression. Oracle introduced in version 11g release 2 a new feature called Advanced Compression which is not covered here. General principle of Oracle compression Oracle compression is a way of reducing the d…
This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

861 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

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now