Gerenios / AADInternals

AADInternals PowerShell module for administering Azure AD and Office 365
http://aadinternals.com/aadinternals
MIT License
1.2k stars 210 forks source link

Open-AADIntOWA - Windows.Forms.Form and Clear-WebBrowser #86

Open realspookysocks opened 3 months ago

realspookysocks commented 3 months ago

When trying to run Open-AADIntOWA from a powershell window, I get the following error:

New-Object : Cannot find type [Windows.Forms.Form]: verify that the assembly containing this type is loaded.

Doing a bit of digging, I'm pretty sure that's because the powershell module doesn't include the required "Add-Type -AssemblyName System.Windows.Forms" and associated assembly references. You can get around this by using powershell ISE, which will auto-load some modules.

After getting around this one, I still was unable to use Open-AADIntOWA successfully. I was getting the error 'Clear-WebBrowser'.

Any help would be greatly appreciated!