Home » RDBMS Server » Server Administration » Students in need; Sending email from database through forms.
Students in need; Sending email from database through forms. [message #369719] Fri, 25 August 2000 07:55 Go to next message
craig houghton
Messages: 2
Registered: August 2000
Junior Member
Please help me in this particular situation, I'm a student at Willis College trying to complete a project in COOP.
My requirement is to send email from Database through forms, using built-ins and PL\SQL Block. OS is windows NT version 4 service pack 5, and Oracle 8.1.5.
We have used the HOST built-in without any result. We've tried to approach it using the tcp_SMTP but we couldn't get it to work this way either. Any Suggestions?

Our Problem is the same as SIVA, who emailed you prior to us.
-------------
Her email included the following:

I am using utl_tcp package options to send the mail. Program is getting compiled. But when i try to execute the program, it is going to exception handling and when i display the error message it says "ORA 29540 class oracle/net/plsql/TCPconnection not available.
How will i add classes to already installed oracle?

We have a SMTP mail server. Is TCP utility function enough or should I use SMTP utilities. If so what should i do to execute the code. Already the TCP as well as SMTP pacakges are available in my database( I am able to view the packages and the functions inside).

If any one can help me to solve this problem, it will be great to me. My doubts are

Is TCP utility enough to send mail.
If so what should I do to overcome the ORA 29540 error ( Jave class not available error).
If not and if i have to use SMTP packages, can any one send me a piece of code ( which is already functioning).
------------
Please get back to us as early as possible as the requirement is urgent.

Thanks in Advance
Marjolaine
Re: Students in need; Sending email from database through forms. [message #369746 is a reply to message #369719] Tue, 03 October 2000 06:57 Go to previous messageGo to next message
SUMESH KUMAR SOLANKI
Messages: 1
Registered: October 2000
Junior Member
you can use the Forms OLE2 package in order to accomplish this. Below, I have included a sample (and simple) program that shows you how to send an email from Oracle forms 4.5 using the Outlook 97 Application object:

PROCEDURE SendMail
objOutlook OLE2.OBJ_TYPE;
objMail OLE2.OBJ_TYPE;
objArg OLE2.LIST_TYPE;
BEGIN
objOutlook := OLE2.CREATE_OBJ('Outlook.Application');
objarg := OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(objarg,0);
objMail := OLE2.INVOKE_OBJ(objOutlook,'CreateItem',objarg);
OLE2.DESTROY_ARGLIST(objarg);
OLE2.SET_PROPERTY(objmail,'To','MyEmailAdress');
OLE2.SET_PROPERTY(objmail,'Subject','Email sent from Oracle Forms 4.5');
OLE2.SET_PROPERTY(objmail,'Body','This is an email that was sent using OLE2 from Oracle forms 4.5');
OLE2.INVOKE(objmail,'Send');
OLE2.INVOKE(objmail,'Display');
OLE2.RELEASE_OBJ(objmail);
OLE2.RELEASE_OBJ(objOutlook);
END;

--------
Re: Students in need; Sending email from database through forms. [message #369926 is a reply to message #369719] Tue, 07 November 2000 13:20 Go to previous message
Randy DeWoolfson
Messages: 6
Registered: November 2000
Junior Member
This is not exactly what you are trying to do as a student, but in real life, you could use the tool EZDBMail.

www.ezdbmail.com

it is easy to install and works by inserting records.. no tcpip programming.

hth
Randy
Previous Topic: Sending email with attachments through pl/sql
Next Topic: ops$ accounts
Goto Forum:
  


Current Time: Fri May 03 17:08:21 CDT 2024