A colleague wanted me to raise a case with Microsoft to see if there was a way to find the owner of a form based on the Id. I did a quick Google and there didn’t seem to be a way… all suggestions were to send the form link modified to open the edit mode around (
https://forms.office.com/Pages/DesignPage.aspx?origin=shell#FormId=<YourFormID>), and see if anyone can open it. Kind of like King Arthur’s sword (“Whoever pulls out this sword from this stone is the true king of England!”) or Thor’s Mjolnir (“Whosoever holds this hammer, if he be worthy, shall possess the power of Thor“). :)
It’s too hot outside and ideally I should be out walking, instead I decided to be unhealthy and sit at home and see if there’s some way to find the owner.
I opened the form and went through the source code (did a quick search for words like “owner”) but didn’t find anything. Then I thought let me dig around with the “Inspect” tools.
So I right clicked and selected “Inspect”. Am on Firefox.
Went to the Network tab and did a Reload.
First I tried the “ResponsePage.aspx” file and its Response headers… but that was just stuck.
The “ResponsePageStartup.ashx” looked interesting. No idea what it is but it was the only other non JS or CSS file I found there… plus it had “Startup” in the name, maybe it does something interesting?
The Response is a JSON. So I kept expanding it (started with “data”).
Under “data” > “Form” I finally struck gold!
Excitedly I did a
Get-MgUser -UserId <theabove> and got nothing. Good thing I didn’t give up, coz I logged into Azure AD and put the Id in the main search page. Turns out it was an M365 group. Sweet!
FYI, the full Url to that page is
ps. The story continues…
Update: Next time, I should use
Get-MgDirectoryObject -DirectoryObjectId "<id>").AdditionalProperties instead of
Get-MgUser. This will work with any object and not error out like above.