I want to get Microsoft 365 activation account information with a PowerShell command

津川 修一 1 Reputation point
2021-07-30T07:22:42.103+00:00

Immediately after installing Microsoft 365, specify the email address on the activation screen,
I want to use the PowerShell command to get the email address information that I entered when setting up this authentication.

You can check it by launching Excel etc. on the target computer and displaying the account screen.
Please let me know if there is a way to investigate with the PowerShell command.
Thank you.

<Postscript>
When I tried ospp.vbs with / dstatus specified,
I was able to get the Product ID and SKU ID information,
I couldn't get the above email address information.
(ERROR CODE: 0x4004FC04 was displayed on the way)

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,462 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Ian Xue (Shanghai Wicresoft Co., Ltd.) 34,271 Reputation points Microsoft Vendor
    2021-08-02T07:11:37.597+00:00

    Hi,

    How about querying the registry value?

    Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Office\16.0\Common\Identity\Identities\*" -Name "EmailAddress"  
    

    Best Regards,
    Ian Xue

    ============================================

    If the Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

  2. 津川 修一 1 Reputation point
    2021-08-03T23:58:31.33+00:00

    Mr. Ian Xue
    The problem has been solved.
    Thank you very much.

    0 comments No comments