Author |
|
gregw Newbie
Joined: 11 May 2006 Location: United States
Online Status: Offline Posts: 5
|
Posted: 11 May 2006 at 10:58am | IP Logged
|
|
|
With the new SMTP Feature, does that mean that I don't need to define an outgoing SMTP Server, and that Mailbee will look for the SMTP Server associated with the email address I'm sending to?
Regarding the Gmail.
I would like to read my Gmail inbox, open each email 1 x 1, and parse the HTML.
Is this something that would be straightforward to do?
Is the Setup to GMail pretty simple?
I don't want want to download the sample and install over my registered version to try first.
Thanks...
|
Back to Top |
|
|
Alex AfterLogic Support
Joined: 19 November 2003
Online Status: Offline Posts: 2206
|
Posted: 11 May 2006 at 12:40pm | IP Logged
|
|
|
Apparently, you meant MailBee.NET Objects instead of MailBee Objects.
Quote:
With the new SMTP Feature, does that mean that I don't need to define an outgoing SMTP Server, and that Mailbee will look for the SMTP Server associated with the email address I'm sending to?
|
|
|
Yes, it's possible.
You can send a message with a single line of code:
Code:
MailBee.SmtpMail.Smtp.QuickSend("jdoe@domain.com", "bill@domain.com", "Subject", "Message
Body");
|
|
|
The advanced way is to create Smtp Object and specify DNS server. The following sample sends the message via DNS (in C# syntax):
Code:
Smtp mailer = new Smtp();
// Add DNS server
mailer.DnsServers.Autodetect();
// Compose the message.
mailer.From.AsString = "jdoe@domain.com";
mailer.To.AsString = "bill@domain.com";
mailer.Subject = "Test message";
mailer.BodyPlainText = "The message text";
// Send it.
mailer.Send();
|
|
|
Quote:
Regarding the Gmail. I would like to read my Gmail inbox, open each email 1 x 1, and parse
the HTML. Is this something that would be straightforward to do? Is the Setup to GMail pretty simple?
|
|
|
The following sample code connects to Gmail, downloads message headers for all "Inbox" messages and prints "From:", "To:" and "Subject:" fields to the standard output stream (in C# syntax):
Code:
// Create Pop3 object
Pop3 pop = new Pop3();
// Set secure connection to Gmail
pop.SslMode = SslStartupMode.OnConnect;
// Connect to Gmail
pop.Connect("pop.gmail.com", 995);
// Log into Gmail account
pop.Login("jdoe", "secret");
// Download headers for all messages
MailMessageCollection oMsgs = oPop.DownloadMessageHeaders();
// For each message, write data to console
foreach (MailMessage oMsg in oMsgs)
{
Console.WriteLine("From: " + oMsg.From.Email + ", To: " + oMsg.To.AsString);
Console.WriteLine("Subject: " + oMsg.Subject);
}
// Disconnect from POP3 server
oPop.Disconnect();
|
|
|
Please note, you should enable POP3 access to your Gmail account via Gmail settings.
Regards,
Alex
|
Back to Top |
|
|
gregw Newbie
Joined: 11 May 2006 Location: United States
Online Status: Offline Posts: 5
|
Posted: 13 May 2006 at 7:25pm | IP Logged
|
|
|
These behaviors are only available in the .NET version and not the version that works with VB6???
Please don't confuse me here...
The sales literature on MailBee objects says this is new...
What's new
SMTP/POP3/IMAP4: S/MIME support (via SSL/SMIME plugin)
SMTP: Creating attachments from memory (binary arrays and strings supported)
SMTP: Sending without dedicated SMTP server (GetRelayServerFromEmailAddress method can do MX lookup for destination SMTP server name)
SMTP: Method for resolving domain names into IP addresses
Can you address my original question again?
After re-reading the Active-X MailBee information it looks as though the SMTP feature is NEW but the GMail feature is not included in the Active-X version.
If you could spell it out for me I would be grateful.
Thanks,
greg
|
Back to Top |
|
|
Alex AfterLogic Support
Joined: 19 November 2003
Online Status: Offline Posts: 2206
|
Posted: 14 May 2006 at 5:28am | IP Logged
|
|
|
Quote:
SMTP: Sending without dedicated SMTP server (GetRelayServerFromEmailAddress method can do MX lookup for destination SMTP server name)
|
|
|
MailBee Objects (ActiveX version) can determine destination SMTP server from email address using this method. However, sending with this method is two-step process:
1) Obtain SMPT server name using GetRelayServerFromEmailAddress method and assign this name to SMTP.ServerName property
2) Send mail using SMTP.Send method
This two-step process needs to be repeated for each recipient if the message has several recipients and these recipients belong to different domains (and thus have different destination SMTP servers).
MailBee.NET Objects version takes care of extracting destination SMTP MX server names, grouping recipients by domains, and sending to corresponding SMTP MX servers automatically. Also, this operation performs much faster because MailBee.NET Objects can send to multiple SMTP MX servers simultaneously (up to 60 threads).
Quote:
After re-reading the Active-X MailBee information it looks as though the SMTP feature is NEW but the GMail feature is not included in the Active-X version.
|
|
|
MailBee Objects (ActiveX version) + MailBee SSL/SMIME plugin can connect to Gmail as well as .NET version:
Code:
Set Pop3 = CreateObject("MailBee.POP3")
Set Ssl = CreateObject("MailBee.SSL")
Pop3.LogFilePath = "C:\pop3_log.txt"
Pop3.EnableLogging = True
Pop3.ClearLog
Pop3.LicenseKey = "POP3 key goes here"
Ssl.LicenseKey = "SSL plugin key goes here"
Set Pop3.Ssl = Ssl
Pop3.PortNumber = 995
Pop3.UserName = "user"
Pop3.Password = "pass"
Pop3.ServerName = "pop.gmail.com"
Set Headers = Pop3.RetrieveHeaders
For Each Header In Headers
MsgBox Header.Subject
Next
Set Msg = POP3.RetrieveSingleMessage(1)
MsgBox Msg.Subject
Pop3.Disconnect
|
|
|
The main difference between ActiveX and .NET versions in this regard is that MailBee Objects license by default does not include MailBee.SSL component (although it's physically present in the DLL). Thus, MailBee SSL key needs to be purchased separately. In MailBee.NET Objects, SSL functionality is covered by the standard license.
Regards,
Alex
|
Back to Top |
|
|
gregw Newbie
Joined: 11 May 2006 Location: United States
Online Status: Offline Posts: 5
|
Posted: 14 May 2006 at 12:39pm | IP Logged
|
|
|
Thanks! I think I understand now... Seems like it may be time to move to VB.Net
Is there an upgrade path from MailBee Active-X to MailBee.Net?
greg
|
Back to Top |
|
|
Alex AfterLogic Support
Joined: 19 November 2003
Online Status: Offline Posts: 2206
|
Posted: 15 May 2006 at 9:15am | IP Logged
|
|
|
We provide 50% discount off the regular price for registered users of any version of MailBee Objects (or any individual MailBee component such as POP3, SMTP, etc).
We would be glad to answer to your questions regarding migration of your applications powered by MailBee Objects to MailBee.NET Objects.
If you're registered user of any of MailBee products, please contact us at support@afterogic.com on how to purchase with the discount.
Regards,
Alex
|
Back to Top |
|
|