I have written a C# application to send an email message using my Office 365 Exchange server.
I can send the message perfectly if I specify the “From” as the Mailbox I log in as (both highlighted below). But I can’t do it if I log in as Mailbox, and send as “Shared Mailbox” address. Here is my code, can this be done?
MailMessage mail = new MailMessage(); mail.From = new MailAddress("SHAREDMAILBOX.AT.SOMEWHERE.com"); mail.To.Add("MYACCOUNT.AT.SOMEWHERE.com"); mail.Subject = "Test Mail";
I am pretty sure, from my time doing exchange migrations that this can be resolved by giving the mailbox which you are authenticating with send as permissions over the other mailbox (es) in the exchange admin centre. If I also remember there is some propagation time so apply send as permissions, wait an hour then try sending.