Skip to main content

How to Configuring outgoing email settings for SharePoint with office 365 out look




Install SMTP role on one of the Servers in the domain which has access to internet, since we need to connect to smtp.office365.com this is must.


Configuring SMTP service so that it can talk to office365 smtp

Open --> IIS 6.0 Manager --> right click on SMTP --> properties

2.1 First we will configure the Access, we don’t have much to configure in this. Check authentication is set to anonymous



2.2 Next click on connection button and you can select which servers can connect to this virtual server, by default it is set to accept all. If you need you can modify as per your orgs security policies








2.3 Next click on relay, here you can select which computer can relay through this SMTP. If you need that any computer / server can relay through this, select all except the list below option






2.4 Next click on Messages tab, here we don’t have to change anything except if you need to change the badmail directory i.e. where SMTP store any email that it fails to deliver due to one or the other reason.












2.5 Next click on delivery tab à outbound security, here chose basic authentication and provide a username and password, remember this user should have a valid exchange online mailbox. Also make sure you check TLS encryption here








2.6 Next click on outbound connections, here we can specify the port as 25 or 587 and leave rest as it is








2.7 Next click on Advanced , here you can provide FQDN name of your domain and smart host which should be set to smtp.office365.com








This completes our SMTP level configuration

3. Testing the connection

3.1 Install telnet client on the server : Server manager à add feature à check Telnet client

3.2 Open cmd prompt and run the following

telnet localhost 25:

helo

mail from:<youroffice365email@domain.com>

rcpt to:<senderemail@dmain.com>

data

subject:test mail

test email

.

Quit








4. Configuring SharePoint server

4.1 CA --> system settings --> outgoing email settings







Make sure that from address have permissions to send email through your exchange online else you will see bad email in your badmail directory on the SMTP Server with the following message in it



Diagnostic-Code: smtp; 550 5.7.1 Client does not have permissions to send as this sender

To test the outgoing email settings just set any alert on one of the document libraries or any list for any user with a valid email address

Comments

Popular posts from this blog

Content Query Webpart Template In SharePoint 2013 and add new column in it

Dear All, Here is the easiest way to make add custom column under your content query web part and then you can format it as you want. Step 1:  Open Sharepoint design Step 2:  Open site for sharepoint parent site collection Step 3:  Locate the following folder Style Library > XLS Style Sheets Step 4:  Open "ItemStyle.xsl"  file Add the custom style sheet as you want <xsl:template name="[Your Style Name]" match="Row[@Style='[Your Style Name]']" mode="itemstyle">                                                   <xsl:param name="CurPos" />                                                     <xsl:variable name="SafeLinkUrl">                                                       <xsl:call-template name="OuterTemplate.GetSafeLink">                                                         <xsl:with-param name="UrlColumnName" select="'LinkU

Updatepanel or Enable Ajax in SharePoint webpart

Dear All It is really giving me a hard to get this techniques if you want to run the update panel in sharepoint 2013 webpart then you need to initialize the script manage by code   protected override void OnInit(EventArgs e)         {             base.OnInit(e);             InitializeControl();             // Register the ScriptManager             ScriptManager scriptManager = ScriptManager.GetCurrent(this.Page);             if (scriptManager == null)             {                 scriptManager = new ScriptManager();                 scriptManager.ID = "ScriptManager1";                 scriptManager.EnablePartialRendering = true;                 Controls.AddAt(0, scriptManager);             }         } In ascx page you need to add the following  <asp:UpdateProgress ID="UpdateProgress1" runat="server">     <ProgressTemplate>         <h1>Your progress value</h1>     </ProgressTemplate> </asp:U

SharePoint: A Complete Guide to Getting and Setting Fields using C#

Original article https://social.technet.microsoft.com/wiki/contents/articles/21801.sharepoint-a-complete-guide-to-getting-and-setting-fields-using-c.aspx Introduction This article demonstrates how to set and get the various SPField types for a SharePoint list using C#. The examples demonstrated set and get fields from an item that belongs to a custom list. The custom list contains a number of fields, and all the fields are named based on the type of field they are. For example, there is a Text field, which has been named, textfield. This is depicted in the following picture:   Applies To The examples demonstrated below are tested with and apply to the following versions of SharePoint: SharePoint 2010 SharePoint 2013 Get the List, and the first SPListItem This is the basic code for getting an item. If the list has at least one item, the first item is retrieved, otherwise a new item is created. var web = SPContext.Current.Site.RootWeb; var list = web.Lists.Try