MailMessageOrganization Property |
Gets or sets the name of organization to which the sender of the message belongs.
Namespace: MailBee.MimeAssembly: MailBee.NET (in MailBee.NET.dll) Version: 12.5.0 build 687 for .NET 4.5
Syntax public string Organization { get; set; }
Public Property Organization As String
Get
Set
Property Value
Type:
String
A string containing the value of Organization header of the message. The default value is an empty string.
Examples This sample loads the message from .EML file and displays the name of the
organization which sent this message.
using System;
using MailBee;
using MailBee.Pop3Mail;
using MailBee.Mime;
class Sample
{
static void Main(string[] args)
{
MailMessage msg = Pop3.QuickDownloadMessage("pop3.mail.com", "kathy1981", "password", 1);
if (msg.Organization != String.Empty)
{
Console.WriteLine("The message was sent by " + msg.Organization);
}
else
{
Console.WriteLine("The message was sent by unknown organization or by person.");
}
}
}
Imports System
Imports MailBee
Imports MailBee.Pop3Mail
Imports MailBee.Mime
Module Sample
Sub Main(ByVal args As String())
Dim msg As MailMessage = Pop3.QuickDownloadMessage("pop3.mail.com", "kathy1981", "password", 1)
If msg.Organization <> String.Empty Then
Console.WriteLine("The message was sent by " & msg.Organization)
Else
Console.WriteLine("The message was sent by unknown organization or by person.")
End If
End Sub
End Module
See Also