Script task fails to send mail to GMAIL

Hi   guys ,
   I am new here and i am glad i that i am here.  I am working in a company  as SQL Server developer(T-sql), i am learning SSIS because  i wanted to move to data warehousing.
I not familiar and i don't know any thing about  C#,  but i am learning SSIS on my own.
I tried to send mail to gmail  using script task , both sender and receiver with same mail ID using variables which i tried using tutorial i found from the below link.
[quote]http://www.codeproject.com/Articles/85172/Send-Email-from-SSIS-with-option-to-indicate-Email[/quote]
but finally when i execute the task , it returns failure message and email is not sent.
[quote]SSIS package "Send mail using script task.dtsx" starting.
Error: 0x8 at Script Task: The script returned a failure result.
Task failed: Script Task
SSIS package "Send mail using script task.dtsx" finished: Success.
[/quote]
Below message taken from progress tab
[quote]Error: The script returned a failure result.[/quote]
Can you all please help me in  finding where i am going wrong? please check below code which i have used in script task.
Microsoft SQL Server Integration Services Script Task
Write scripts using Microsoft Visual C# 2008.
The ScriptMain is the entry point class of the script.
using System;
using System.Data;
using Microsoft.SqlServer.Dts.Runtime;
using System.Windows.Forms;
using System.Text.RegularExpressions;
using System.Net.Mail;
namespace ST_9bc84810a62a401aa44ddd905bcd369d.csproj
[System.AddIn.AddIn("ScriptMain", Version = "1.0", Publisher = "", Description = "")]
public partial class ScriptMain : Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase
#region VSTA generated code
enum ScriptResults
Success = Microsoft.SqlServer.Dts.Runtime.DTSExecResult.Success,
Failure = Microsoft.SqlServer.Dts.Runtime.DTSExecResult.Failure
#endregion
The execution engine calls this method when the task executes.
To access the object model, use the Dts property. Connections, variables, events,
and logging features are available as members of the Dts property as shown in the following examples.
To reference a variable, call Dts.Variables["MyCaseSensitiveVariableName"].Value;
To post a log entry, call Dts.Log("This is my log text", 999, null);
To fire an event, call Dts.Events.FireInformation(99, "test", "hit the help message", "", 0, true);
To use the connections collection use something like the following:
ConnectionManager cm = Dts.Connections.Add("OLEDB");
cm.ConnectionString = "Data Source=localhost;Initial Catalog=AdventureWorks;Provider=SQLNCLI10;Integrated Security=SSPI;Auto Translate=False;";
Before returning from this method, set the value of Dts.TaskResult to indicate success or failure.
To open Help, press F1.
public void Main()
string sSubject = "Test Subject";
string sBody = "Test Message";
int iPriority = 2;
if (SendMail(sSubject, sBody, iPriority))
Dts.TaskResult = (int)ScriptResults.Success;
else
//Fails the Task
Dts.TaskResult = (int)ScriptResults.Failure;
public bool SendMail(string sSubject, string sMessage, int iPriority)
try
string sEmailServer = Dts.Variables["sEmailServer"].Value.ToString();
string sEmailPort = Dts.Variables["sEmailPort"].Value.ToString();
string sEmailUser = Dts.Variables["sEmailUser"].Value.ToString();
string sEmailPassword = Dts.Variables["sEmailPassword"].Value.ToString();
string sEmailSendTo = Dts.Variables["sEmailSendTo"].Value.ToString();
string sEmailSendCC = Dts.Variables["sEmailSendCC"].Value.ToString();
string sEmailSendFrom = Dts.Variables["sEmailSendFrom"].Value.ToString();
string sEmailSendFromName = Dts.Variables["sEmailSendFromName"].Value.ToString();
SmtpClient smtpClient = new SmtpClient();
MailMessage message = new MailMessage();
MailAddress fromAddress = new MailAddress(sEmailSendFrom, sEmailSendFromName);
//You can have multiple emails separated by ;
string[] sEmailTo = Regex.Split(sEmailSendTo, ";");
string[] sEmailCC = Regex.Split(sEmailSendCC, ";");
int sEmailServerSMTP = int.Parse(sEmailPort);
smtpClient.Host = sEmailServer;
smtpClient.Port = sEmailServerSMTP;
System.Net.NetworkCredential myCredentials =
new System.Net.NetworkCredential(sEmailUser, sEmailPassword);
smtpClient.Credentials = myCredentials;
message.From = fromAddress;
if (sEmailTo != null)
for (int i = 0; i < sEmailTo.Length; ++i)
if (sEmailTo[i] != null && sEmailTo[i] != "")
message.To.Add(sEmailTo[i]);
if (sEmailCC != null)
for (int i = 0; i < sEmailCC.Length; ++i)
if (sEmailCC[i] != null && sEmailCC[i] != "")
message.To.Add(sEmailCC[i]);
switch (iPriority)
case 1:
message.Priority = MailPriority.High;
break;
case 3:
message.Priority = MailPriority.Low;
break;
default:
message.Priority = MailPriority.Normal;
break;
//You can enable this for Attachments.
//SingleFile is a string variable for the file path.
//foreach (string SingleFile in myFiles)
// Attachment myAttachment = new Attachment(SingleFile);
// message.Attachments.Add(myAttachment);
message.Subject = sSubject;
message.IsBodyHtml = true;
message.Body = sMessage;
smtpClient.Send(message);
return true;
catch (Exception ex)
return false;
Please help me resolve this guys ... THANKS IN ADVANCE

Thank you very much for your reply @Elvis Long,
Sorry for the late reply
Actually, i am not trying or executing this task  from my office , but i am trying this at my home :( .
sEmailPort has value 587 sEmailServer has smtp.gmail.com
Can you please check whether this C# coding is correct or not ? because finally it gives error saying "Script
Task: The script returned a failure result" 
so can you please check this with your system and let me know what is wrong with this code
Thanks in advance  

Similar Messages

  • Java mail api - sending mails to gmail account

    Hello
    I am using java mail api to send mails.when i send mails to gmail from ids which are not in gmail friends list, most of the mails are going to spam.Ofcourse, some of them go to inbox.I tried in lot of ways to analyse the problem.But nothing could help. Can anyone plzz tell me how to avoid mails going to spam in gmail, using java mail api?
    Thank you in advance,
    Regards,
    Aradhana
    Message was edited by:
    Aradhana

    am using the below code.
    Properties props = System.getProperties();
    //          Setup mail server
              props.put("mail.smtp.host", smtpHost);
              props.put("mail.smtp.port","25");
              props.put("mail.smtp.auth", isAuth);
         Authenticator auth = new UserAuthenticator();
    //          Get session
              Session s = Session.getDefaultInstance(props,auth);
    //          Define message
              Message m = new MimeMessage(s);
    //          setting message attributes
              try {
                   m.setRecipient(Message.RecipientType.TO, new InternetAddress(to));
                   InternetAddress f_addr=new InternetAddress(from);
                   f_addr.setPersonal(personalName);
                   m.setFrom(f_addr);               
                   m.setSubject(subject);
                   m.setSentDate(new Date());
                   m.setContent(msg,"text/plain");
                   m.saveChanges();
    //               send message
                   Transport.send(m);
    Message was edited by:
    Aradhana

  • Notifications failed to send mail for journal approval with attachments

    Issue : Notifications failed to send mail for journals sent for approvals with attachments.
    Error :
    [WF_ERROR] ERROR_MESSAGE=3835: Error '-6502 - ORA-06502: PL/SQL: numeric or value error: character string buffer too small' encountered during execution of Generate function 'WF_XML.Generate' for event 'oracle.apps.wf.notification.send'. ERROR_STACK=
    WF_XML.GetAttachments(71009549, http://vfilvappclone.verifone.com:8000/pls/EBIZRPT, 13525)
    WF_XML.GenerateDoc(oracle.apps.wf.notification.send, 71009549)
    WF_XML.Generate(oracle.apps.wf.notification.send, 71009549)
    WF_XML.Generate(oracle.apps.wf.notification.send, 71009549)
    Wf_Event.setMessage(oracle.apps.wf.notification.send, 71009549, WF_XML.Generate)
    Wf_Event.dispatch_internal()
    Cause : Above error is thrown for Journals with attachment of file type Microsoft Office Excel Macro-Enabled Worksheet (.xlsm)
    Can anybody help with this?

    Please post the details of the application release, database version and OS.
    Please see if these docs help.
    ORA-20001 & ORA-06502 Workflow Errors [ID 761638.1]
    Manager Approval Notification Gives Error: Ora-O6502: Pl/Sql: Numeric Or Value Error: Character String Buffer Too Small [ID 352213.1]
    Approval Confirmation Email Is Not Received By Preparer - ERROR_MESSAGE=3835 ORA-20001 ORA-6502 [ID 465146.1]
    Notification Fails To Be Generated When A DOCX Document Is Attached [ID 1058183.1]
    Not Able To Send Multiple E-Mails Upon Approval Of Purchase Order [ID 333719.1]
    Expenses Workflow Error: "ORA-06502: PL/SQL: numeric or value error: associative array shape is not consistent with session parameters has been detected in fnd_global.put(CONC_LOGIN_ID,-1)" [ID 455882.1]
    Using Microsoft Office 2007 and 2010 with Oracle E-Business Suite 11i and R12 [ID 1077728.1] -- Notification Generation Fails
    ORA-06502 Buffer Too Small Error in Contracts Workflow Notification [ID 870712.1]
    Thanks,
    Hussein

  • Failed to send mail to external domain via portal

    Hi Gurus,
    By following the configuraion instructions in <b>SAP library - Collaboration - Groupware - Installing and Configuring E-Mail Connectivity</b>, I managed to send mail to recipients who reside in same domain e.g. <b>[email protected]</b> via portal.
    However, I failed to send mail to external domain e.g. <b>[email protected]</b>. I got the following error message:
    The mail could not be sent to the specified recipients com.sap.ip.collaboration.gw.impl.transport.javamail.exception.MailSendException: The mail could not be sent to the specified recipients
         at com.sap.ip.collaboration.gw.impl.transport.javamail.JavaMailTransport.sendMail(JavaMailTransport.java:183)
    --------- exception is chained. Original exception ------------
    javax.mail.SendFailedException: Invalid Addresses;
      nested exception is:
         javax.mail.SendFailedException: 553 sorry, that domain isn't in my list of allowed rcpthosts (#5.7.1)
         at com.sun.mail.smtp.SMTPTransport.rcptTo(SMTPTransport.java:804)
         at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:320)
    Please help.
    Thanks alot.

    Hi Ajey,
    Thanks for your reply. I had tried your suggestion but same problem occurred with same error output.
    Actually, I encounterred this error message before in my <b>Microsoft Outlook</b>, where System Admin returned me a mail saying that, my mail was undeliverable with the same error message. But this can be solved by applying the <b>Internet Email Account Setting - Outgoing Server - My outgoing server (SMTP) require authentication</b>.
    So I am wondering,
    1) This problem is caused by SMTP server?
    2) Is there any workaround (like the Outlook Setting) I can configure in Portal?
    Do you have any idea?
    Thanks,
    HauChee

  • Failed to send mail: java.lang.NullPointerException

    Hi @,
    I have configured my receiver mail adpter and while running it is throwing the following error in adapter engine and there is no trace availble to analyse the same Only the follwoing error :
    "failed to send mail: java.lang.NullPointerException"
    Any help Its urgent.
    Regards

    This is strange...some times this types of errors drives crazy isn't....delete it and recreate it.
    just curious the service for mail adapter  in Visaual admin is up right?

  • [nQSError: 75006] Failed to send MAIL Command

    Hello,
    We are on AIX and Siebel Analytics 7.8.5. We are having a weird issue with ibots. Wwe have around 800 ibots and only 65 of them fail with *[nQSError: 75006] Failed to send MAIL Command* this error. These ibots use to work good. I have created some test ibots and even those fail with the same error.
    Does any one have an idea..how to resolve this?
    Thanks in advance

    We are using Exchange Server. We are able to send e-mails to many usres....that means the credentials are correct. If we reschedule a delivered report..it is successful.
    Eventually succeeded, but encountered and resolved errors...
    Number of skipped recipients: 1 of 2
    +++ ThreadID: 8ca6 : 2010-09-23 09:30:37.000
    iBotID: /shared/_iBots/NBR - ED and Mktg/NBR Alert - Private Equipment
    [nQSError: 75006] Failed to send MAIL command.
    +++ ThreadID: 8ca6 : 2010-09-23 09:30:37.000
    iBotID: /shared/_iBots/NBR - ED and Mktg/NBR Alert - Private Equipment
    ...Trying SMTP Delivery loop again
    +++ ThreadID: 8ca6 : 2010-09-23 09:30:37.000
    ... Sleeping for 9 seconds.
    +++ThreadID: 8ca6 : 2010-09-23 09:30:46.000
    iBotID: /shared/_iBots/NBR - ED and Mktg/NBR Alert - Private Equipment
    [nQSError: 75006] Failed to send MAIL command.
    +++ ThreadID: 8ca6 : 2010-09-23 09:30:46.000
    iBotID: /shared/_iBots/NBR - ED and Mktg/NBR Alert - Private Equipment
    ...Trying SMTP Delivery loop again
    +++ ThreadID: 8ca6 : 2010-09-23 09:30:46.000
    ... Sleeping for 4 seconds.
    +++ ThreadID: 8ca6 : 2010-09-23 09:30:50.000
    iBotID: /shared/_iBots/NBR - ED and Mktg/NBR Alert - Private Equipment
    [nQSError: 75006] Failed to send MAIL command.
    Thanks

  • Error in sending mail to Gmail :-(

    Hi,
    I am trying to send mail to gmail from my program but I am getting the following error.......Please suggest the solution and cause of problem.
    Prog:_
    import java.util.*;
    import javax.mail.*;
    import javax.mail.internet.*;
    public class Mail {
         public static void main(String[] args) throws Exception{
              Properties props = new Properties();
              String mailMessage="ur friend Here";
              props.put("mail.smtp.host","smtp.Gmail.com");
              Session s = Session.getInstance(props,null);
              MimeMessage message = new MimeMessage(s);
              InternetAddress from = new InternetAddress("[email protected]");
              message.setFrom(from);
              InternetAddress to = new InternetAddress("[email protected]");
              message.addRecipient(Message.RecipientType.TO, to);
              message.setSubject("It is Urgent....");
              message.setContent(mailMessage, "text/html");
              Transport.send(message);
              System.out.println("sent");
    O/P_
    Exception in thread "main" com.sun.mail.smtp.SMTPSendFailedException: 530 5.7.0
    Must issue a STARTTLS command first i6sm12879368wxd.21
    at com.sun.mail.smtp.SMTPTransport.issueSendCommand(SMTPTransport.java:1515)
    at com.sun.mail.smtp.SMTPTransport.mailFrom(SMTPTransport.java:1054)
    at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:634)
    at javax.mail.Transport.send0(Transport.java:189)
    at javax.mail.Transport.send(Transport.java:118)
    at Mail.main(Mail.java:31)
    Thanks
    Deviprasad

    Hi,
    I tried with props.put("mail.smtp.starttls.enable","true"); but the following error message
    Exception in thread "main" javax.mail.MessagingException: Exception reading resp
    onse;
    nested exception is:
    java.net.SocketException: Connection reset
    at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:1611)
    at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1369)
    at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:412)
    at javax.mail.Service.connect(Service.java:288)
    at javax.mail.Service.connect(Service.java:169)
    at javax.mail.Service.connect(Service.java:118)
    at javax.mail.Transport.send0(Transport.java:188)
    at javax.mail.Transport.send(Transport.java:118)
    at Mail.main(Mail.java:31)
    Caused by: java.net.SocketException: Connection reset
    at java.net.SocketInputStream.read(Unknown Source)
    at com.sun.mail.util.TraceInputStream.read(TraceInputStream.java:110)
    at java.io.BufferedInputStream.fill(Unknown Source)
    at java.io.BufferedInputStream.read(Unknown Source)
    at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:88)
    at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java
    :1589)
    ... 8 more
    Plz help....

  • Transaction failed: Cannot send mail due to possible abuse

    For the past two days, I have not been able to send mail from one of my Verizon.net sub-accounts using Mozilla Thunderbird. However I can send mail from the Verizon Yahoo webmail website.
    I get this error message:
    An error occurred while sending mail. Transaction failed: Cannot send mail due to possible abuse; please visit http://postmaster.yahoo.com/abuse_smtp.html for more information.
    And when I click on "OK" in the message box, this second error message pops up:
    Sending of message failed. The message could not be sent because the connection to SMTP server outgoing.yahoo.verizon.net was lost in the middle of the transaction. Try again or contact your network administrator.
    When I go to http://postmaster.yahoo.com/abuse_smtp.html, there is just a generic Yahoo help page, with nothing specific about this problem.

    The possible abuse is likely a 24 hour hold for accounts suspected of sending Spam. Are you still having issues? Also what ports do you have the incoming/outgoing server set to?
    Anthony_VZ
    **If someones post has helped you, please acknowledge their assistance by clicking the red thumbs up button to give them Kudos. If you are the original poster and any response gave you your answer, please mark the post that had the answer as the solution**
    Notice: Content posted by Verizon employees is meant to be informational and does not supersede or change the Verizon Forums User Guidelines or Terms or Service, or your Customer Agreement Terms and Conditions or plan

  • Can't send mail using gmail in Mail 2.1.3 (OSX 10.4.11)

    Hi, it seems like I can receive mail but I get the following error message when I try to send mail:
    Cannot send message using the server (null)
    The server response was: 5.7.0 From address is not one of your address
    I did set up the account information for outgoing mail server (smtp): smtp.gmail.com: username
    CAn anyone help me?

    Hi, did you set up according to these Standard instructions:
    http://mail.google.com/support/bin/answer.py?hl=en&answer=13287
    Especially the...
    Please note that if your client does not support SMTP authentication, you won't be able to send mail through your client using your Gmail address.
    Also, if you're having trouble sending mail but you've confirmed that encyrption is active for SMTP in your mail client, try to configure your SMTP server on a different port: 465 or 587.

  • Convert sap script to pdf and send mail before close_form

    hi experts,
    I am converting a sap script to PDF and then sending that pdf to vendor mail ids.
    I am getting the Data for the conversion of pdf From close_form.But it contains the data for all the vendors . But i have to Send the mail to the specific vendors.For ex if my script output has 5 sheets each with different vendors . I have to send  1 sheet as a pdf mail for that particular vendor. so,1 sheet each for 5 differrent vendors . But the data i get from close_form is the data for all the 5 vendors. How to split the data ?. can any one help me on this issue.
    with thanks in advance,
    syed

    Hi,
        Change your driver program so that it calls the script n no of times .. and every time send mail to particular vendor ..
        Loop at vendors.
         call the form ...
         send mail ...
        endloop ...
    Regards,
    Srini.

  • Reporting Subscriptions Failing - "Failure Sending Mail". Must be something obvious!

    I've spent the last few hours on this and cannot for the life of me figure what it is that I have overlooked. I have created a report email subscription, nothing particularly fancy. It is always failing on:
    Failure sending mail: The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.7.1 Client was not authenticated
    The setup:
    SCCM 2012 R2
    SQL Server 2012 (on the SCCM server)
    Exchange 2010
    SCCM - Email Notification Component is configured correctly. The SMTP test works and I also receive alerts when one of my SCEP rules are triggered. All good.
    SQL Management Studio - DataBase  Mail is configured; sending a test e-mail works. Using Basic Authentication with a network account specified.
    Exchange 2010 has a Receiver Connector created to relay e-mails from the SCCM Server.
    Reporting Services Configuration Manager - Email Section has been completed.
    Can anyone point me in the right direction?

    Hi Garth,
    Thanks for the response. I was under the impression that CM12 uses SSRS (and thus the SQL Mail configuration) to send out the Subscription Reports, if that is definitely not the case I can eliminate that part from my configuration all together.
    So, to clarify:
    CM12 Alerts have always been working fine - no issue here and I understand this is a different kettle of fish to SSRS.
    <cite class="ipb" style="padding:0px 10px 8px;border-width:0px 2px 2px;border-left-style:solid;border-left-color:#989898;border-bottom-style:solid;border-bottom-color:#e5e5e5;border-right-style:solid;border-right-color:#e5e5e5;font-weight:bold;font-style:normal;overflow-x:auto;margin:-1px
    -12px 8px;width:1299px;display:block;-webkit-user-select:none;background:-webkit-gradient(linear, 0% 0%, 0% 100%, from(rgb(246, 246, 246)), to(rgb(229, 229, 229)));">Quote</cite>Why do you think that SSRS can send test message, where did you do this action?
    I actioned the "Send Test E-mail" option when you right-click on the Database Mail option within SQL2012. However, as you pointed out already, if this has absolutely
    nothing to do with the Subscription Reports configuration, then this is no longer relevant. If anything it just proves that e-mails can be sent via the Exchange server (using basic authentication).
    Now, I guess, I just need to figure what within SSRS Configuration Manager is missing, my trouble is that there isn't any detailed settings I can configure
    and Exchange logs doesn't indicate anything that isn't already reported by SCCM:
    2014-06-25T14:09:14.168Z,Exchange\SCCM01 - Subscription Reports Receiver,08D15B57A7508DA3,21,10.2.2.202:25,10.2.2.213:63905,>,530 5.7.1 Client was not authenticated,

  • Can't send mail - says gmail server can't be found? was fine yesterday

    mac air wont send mail - says it cant connect the gmail server?

    it is also showing error 54:conection reset by peer ??

  • Problem in Sending mail thru gmail........

    i am new to Java mail API,can any one help me out...
    i have gmail a/c named [email protected] and it is smtp enabled.
    now i want to send mail from my application.so, i write the following code....but it give some error as describe follow.....
              /**************** Code **************/
    package mailsend;
    import java.util.*;
    import java.io.*;
    import javax.mail.*;
    import javax.mail.internet.*;
    import javax.activation.*;
    Mahesh Dave. 9960497637
    public class Main {
         static String msgText1 = "This is a message body.\nHere's line two.";
         static String msgText2 = "This is the text in the message attachment.";
    /** Creates a new instance of Main */
    public Main() {
    * @param args the command line arguments
    public static void main(String[] args) {
    // TODO code application logic here
    String to = "[email protected]";
              String from = "[email protected]";
              String host = "smtp.gmail.com";
              boolean debug = Boolean.valueOf(false).booleanValue();
              // create some properties and get the default Session
              Properties props = new Properties();
              props.put("mail.smtp.host", host);
              Session session = Session.getInstance(props, null);
              session.setDebug(debug);
              try
                   // create a message
                   MimeMessage msg = new MimeMessage(session);
                   msg.setFrom(new InternetAddress(from));
                   InternetAddress[] address = {new InternetAddress(to)};
                   msg.setRecipients(Message.RecipientType.TO, address);
                   msg.setSubject("JavaMail APIs Multipart Test");
                   msg.setSentDate(new Date());
                   // create and fill the first message part
                   MimeBodyPart mbp1 = new MimeBodyPart();
                   mbp1.setText(msgText1);
                   // create and fill the second message part
                   MimeBodyPart mbp2 = new MimeBodyPart();
                   // Use setText(text, charset), to show it off !
                   mbp2.setText(msgText2, "us-ascii");
                   // create the Multipart and its parts to it
                   Multipart mp = new MimeMultipart();
                   mp.addBodyPart(mbp1);
                   mp.addBodyPart(mbp2);
                   // add the Multipart to the message
                   msg.setContent(mp);
                   // send the message
                   Transport.send(msg);
              catch (MessagingException mex)
                   mex.printStackTrace();
                   Exception ex = null;
                        if ((ex = mex.getNextException()) != null)
                             ex.printStackTrace();
                   /*************** Error **************/
    init:
    deps-jar:
    Compiling 1 source file to C:\Documents and Settings\Administrator\My Documents\MailSend\build\classes
    compile:
    run:
    javax.mail.NoSuchProviderException: smtp
    at javax.mail.Session.getService(Session.java:768)
    at javax.mail.Session.getTransport(Session.java:708)
    at javax.mail.Session.getTransport(Session.java:651)
    at javax.mail.Session.getTransport(Session.java:631)
    at javax.mail.Session.getTransport(Session.java:686)
    at javax.mail.Transport.send0(Transport.java:166)
    at javax.mail.Transport.send(Transport.java:98)
    at mailsend.Main.main(Main.java:81)
    BUILD SUCCESSFUL (total time: 7 seconds)
    So can any one help to solve above probs........and also i want to made atachement inform of file.....anyone have any idea about this, can help.....
    Thank you in advance.....

    You've read the JavaMail FAQ, right? If not, please do now.
    You've also found and tried the many sample programs that
    come with JavaMail, right?
    javax.mail.NoSuchProviderException: smtp
    This error is often a result of not using mail.jar directly but instead extracting
    the classes from mail.jar and adding them to your application. Don't do that.
    If that's not what you did, I need more information about your environment,
    such as your CLASSPATH setting.

  • Trouble sending mail through Gmail with Apple Mail

    I am having trouble sending email through Gmail using Apple Mail.  I have entered the correct password thorugh the two step verification from Google and the Connection Doctor says that I'm connected to the IMAP and SMTP, but I get the error that my email address was rejected by the gmail server. 
    Any thoughts?

    Google has instruction posted for setting up your iPhone with gmail. I followed these directions and it worked perfectly.
    https://mail.google.com/support/bin/answer.py?hl=en&answer=77702

  • Can't send mails from gmail

    I cannot send mails on my MAC book pro mail accounts, I get error messages that SMTP server cannot be contacted, all accounts are off line, even though mails are connected to the internet.

    If it's been functioning normally until now and you haven't changed anything, give it a few hours. Google was having mail problems last week too.

Maybe you are looking for

  • Texts are coming through as email addresses

    twice when ive  texted a coworker from my cell phone and they show me the message it says that the sender of the text is my personal gmail account NOT my phone number like it should be why the **** is it doing this?

  • Commutatio​n with 6280 DAQ Card

    Hello, I want to perform parameter identification of a three phase brushless DC servo motor. Basically I want to obtain mass moment of inertia, viscous damping coefficient and coulomb friction at the bearing. To do so, I plan to apply a step voltage

  • Saved files as .PSD now they are "Windows Shell Common Dll" and won't open?

    I am having a problem with opening some files in Photoshop. I am using Photoshop CS5.1 Extended (Version 12.1) and have Windows 7 64 bit SP1 OS. I am trying to open a few templates I made in PhotoShop for a client and they worked fine when I used the

  • How to create 5D Mark II proxies for rapid editing?

    I've never done transcoding workflows, but I have the basic concepts down. I want to take the native h264 footage from the new 5D Mark II camera, transcode to low-res proxies in ProRes 422, but the file size is gigantic. I want a format that will wor

  • Restrictions belonging relation between Change Request and Corrections?

    Hi all, In standard change process I only can create one change document (correction) to one change request. Releation 1:1. Is there a technical restriction belonging the relation between the change request and the corrections? Does anyone has experi