Forum Discussion
Adding to Distribution List
- Dec 16, 2021Name and Display name are two different parameters, what I'm saying is you should be able to keep display name as "FFF LLLL" while providing a unique value for the Name parameter.
When I try Get-Recipient I get the message: "Get-Recipient: The operation couldn't be performed because object 'XXX XXXXX' couldn't be found on 'CY4PR10A02DC004.NAMPR10A002.PROD.OUTLOOK.COM'."
Which makes sense because the user doesn't have a mailbox.
I am not sure what you mean about referencing a user as I don't have a choice in what to enter. Display Name and Email are required fields.
Thanks
I would just create a mail contact.
https://docs.microsoft.com/en-us/exchange/recipients-in-exchange-online/manage-mail-contacts
- John TwohigDec 15, 2021Iron Contributor
That is the problem. It won't let me create a mail contact. I didn't realize until I saw the message from VasilMichev that using Powershell would bypass the checking.
I was just about to do that when I saw your message that a mail object doesn't have to be internal. I am not sure how to create one but it gives me a direction to try a couple of things. If they don't work for me right away I will just create the mail contact with Powershell.
Thanks
- phorrigan2475Dec 15, 2021Copper ContributorMakes sense, let us know if it doesn't work.
- John TwohigDec 15, 2021Iron Contributor
It didn't work in PowerShell. New-MailContact doesn't bypass the checking. I still get the same error message.
I don't think I am trying to do something unusual. I think I am missing something so I will try to be more precise about what I am doing:
- I have a new user FFF LLLL who needs access to some O365 and on-premises resources but doesn't need an O365 mailbox
- I need to add him to a Distribution List with his personal email address.
So I did the following:
- I created the user in our on-premises AD with:
- FirstName: FFF
- LastName: LLLL
- UPN: mailto:Email address removed
- ADConnect then synced the user to our Azure AD and O365
- The user then had access to the O365 resources he needed
- I then tried to add a mail contact with a name FFF LLLL and external email mailto:Email address removed but got the message that "There are multiple recipients matching identity "FFF LLLL". Please specify a unique value."
Am I trying to go about this the wrong way?