Tuesday, July 14, 2015

How to navigate to an URL in Internet Explorer using powershell?

To navigate to an URL use the New-Object definition as in the following: (in this case http://www.bing.com/news):
PS C:\Users\Jayaram> $ie = New-Object -com InternetExplorer.Application

You get to display the following (contents will be different):


Can you change the size of the window?

Yes, you can change as shown by adding attributes.


When you run the above in Windows PowerShell you get to display a different sized window:


These are supported for the Internet COM Object in PowerShell:


No comments: