• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 56
  • Last Modified:

Error when trying to resolve winmail.dat problem in Office 365


I am getting the attached error when trying to run through the following fix for Office 365 emails.

Open Powershell as an Admin

Set-ExecutionPolicy RemoteSigned

$UserCredential = Get-Credential

(input office 365 admin login details)

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection

Import-PSSession $Session

Set-RemoteDomain Default -TNEFEnabled $false

To confirm that the setting change was applied use:

Get-RemoteDomain |fl

In the returned results, look for:  TNEFEnabled:  False

The above fix is intented to resolve the winmail.dat problem that happens with some recipients when sending to btinernet accounts.

Is it possible someone would be able to shed any light on what this error means please?

Any help is appreciated.

Kind regards,
Systemagic Support.
  • 3
  • 3
1 Solution
Vasil Michev (MVP)Commented:
I dont see any attachment, maybe try uploading it again?
systemagicAuthor Commented:
Apologies, can you now see the attachment?
Vasil Michev (MVP)Commented:
Yup. It seems that the user you are connected with doesnt have the necessary permissions. Make sure you run it with a user that has at least the Exchange admin role.
Problems using Powershell and Active Directory?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

systemagicAuthor Commented:
Thank you for that Vasil, I have had a look in the Exchange admin center and can't find anywhere to assign the Exchange admin role to that user.

Do you know where I need to be looking in there please?

Thanks for your help.
Vasil Michev (MVP)Commented:
Go to the O365 portal -> Admin -> Users -> select the users -> Roles -> assign the Exchange admin role (or Global admin). Or simply run the cmdlet with account that already has the permissions.
systemagicAuthor Commented:
Thanks for your help, believe this has resolved it.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

  • 3
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now