I’ve recently been working on a project with a client to introduce emailing of remittences to suppliers. To do this, we switched them from using Outlook foe sending emails to using a shared Exchange mailbox which their IT created for them.
We discovered that while I could use by email address for logging into Exchange, they couldn’t use their shared mailbox. My initial thought was that while we were both using Office365 accounts, they were trying to use an ordinary password, whereas I was using an app password.
I checked that they were entering the credentials correctly, which for Office365 is to use the email address in both the Email Address and Login ID fields (as shown in the example below), and they were:
After a few minutes checking for other issues, I remembered they were on an older version of Dynamics GP (2015 R2) and older versions did have some problems with the log on to Office365.
I checked the User Exchange Server Address Master (SY04920) table and there were rows for the DYNSA account I was logged in with, but no other accounts. I created a script to populate the table with details for all users and got them to try to log on again, and it worked successfully.
This is the script I used, which sets the same email address against all users:
Created by Ian Grieve of azurecurve|Ramblings of a Dynamics GP Consultant (http://www.azurecurve.co.uk) This code is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0 Int). */ INSERT INTO SY04920 ( USERID,Exchange_Address,Exchange_Server_URL ) -- VALUES ( SELECT USERID ,'email@example.com' ,'https://outlook.office365.com/EWS/Exchange.asmx' FROM SY01400 AS ['Users Master'] WHERE UserStatus = 1 AND ( SELECT COUNT(*) FROM SY04920 WHERE USERID = ['Users Master'].USERID ) = 0 ) GO
I think later versions of Dynamics GP do better at connecting with Office365, but have posted the script so it is easy to find should I need it again.