Home » Developer & Programmer » Forms » Send an email from my Application forms (forms 10g,xp sp2)
Send an email from my Application forms [message #585611] Tue, 28 May 2013 06:21 Go to next message
goldray
Messages: 108
Registered: December 2012
Senior Member
Hi,
I want to send an email from my Application forms 10g .But I receive

code:
DECLARE
l_mailhost VARCHAR2(64) :=... //admin mail
l_from VARCHAR2(64) := ... //admin mail
l_to VARCHAR2(64) := ...//user mail
l_mail_conn sys.UTL_SMTP.connection;
BEGIN
l_mail_conn := UTL_SMTP.open_connection(l_mailhost, 25);
UTL_SMTP.helo(l_mail_conn, l_mailhost);
UTL_SMTP.mail(l_mail_conn, l_from);
UTL_SMTP.rcpt(l_mail_conn, l_to);
UTL_SMTP.data(l_mail_conn, 'HELLO' || CHR(13) || CHR(13));
UTL_SMTP.quit(l_mail_conn);
message('mail sent');
message('mail sent');
exit_form(no_validate);
exception when others then
message('no internet connection');
message('no internet connection');
END;

message displayed is: no internet connection !!
Re: Send an email from my Application forms [message #585614 is a reply to message #585611] Tue, 28 May 2013 06:27 Go to previous messageGo to next message
cookiemonster
Messages: 13922
Registered: September 2008
Location: Rainy Manchester
Senior Member
So remove the pointless exception handler and find out what the real error is.
Re: Send an email from my Application forms [message #585615 is a reply to message #585614] Tue, 28 May 2013 06:44 Go to previous messageGo to next message
goldray
Messages: 108
Registered: December 2012
Senior Member
when I remove the exception,
I receive the following message:
FRM-40735 (When button pressed) ORA-29278
Re: Send an email from my Application forms [message #585617 is a reply to message #585615] Tue, 28 May 2013 07:01 Go to previous message
Littlefoot
Messages: 21809
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Oracle

ORA-29278: SMTP transient error: string

Cause: A SMTP transient error occurred.

Action: Correct the error and retry the SMTP operation.

Check what people did to fix it.
Previous Topic: Do you want to save changes yes/no button code
Next Topic: Concatenate or copy value on enter or WVI
Goto Forum:
  


Current Time: Thu May 09 02:48:05 CDT 2024