Question

I send mail from vmime using the following code:

vmime::string urlString;

urlString="smtp://outgoing.verizon.net";

vmime::utility::url url(urlString);

vmime::ref <vmime::net::transport> tr =
g_session->getTransport(url,vmime::create <interactiveAuthenticator>());

// You can also set some properties (see example7 to know the properties

// available for each service). For example, for SMTP:
tr->setProperty("options.need-authentication", true);
tr->setProperty("auth.username", userName);
tr->setProperty("auth.password", password);
fromString=userName+"@verizon.net";
vmime::mailbox from(fromString);
vmime::mailboxList to;
toString = toUserName+"@verizon.net";
to.appendMailbox(vmime::create <vmime::mailbox>(toString));
std::ostringstream data;
data<<subjectId;
// Connect to server
tr->connect();
// Send the message
vmime::string msgData = data.str();
vmime::utility::inputStreamStringAdapter vis(msgData);
tr->send(from, to, vis, msgData.length());
logMsg(DEBUG,2,"Thread Id: %ld,Sent the data in the transaction",pthread_self());

I see that the sent data is succesful from the log. But when i connect to the box[to which the mail was sent] and check the inbox, i see 0 mails to that inbox. There is no excepton or error from vmime. when i connect to the web version of the mail box.Iam unable to see any transactions is sent box, even for the succesful mails.Can anyone help how i can see the mails sent in the sent box? Thanks in advance.

No correct solution

OTHER TIPS

use any sniffer to catch SMTP traffic from your host. if everything looks good (i.e. SMTP session correct), then it's not a problem of your host, but remote MTA (make sure your email wasn't detected as SPAM & etc)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top