How can find internet explorer version

Hi Team,

I am looking script which can find internet explorer version . I need to run this script among 1000 servers.

can anyone help me on this .....?

February 6th, 2015 2:31am

Hello Triyambak,

You could try this , hope WinRM and PS remoting are all good on those 1000+ servers

Function Get-IEVersion
{

Param([string]$computer = $env:COMPUTERNAME)
Write-Output $computer
Get-ItemProperty -path 'HKLM:\SOFTWARE\Microsoft\Internet Explorer' -ErrorAction SilentlyContinue | select-object Version,svcUpdateVersion | Select-Object -Property "Version",@{Name="Updated to Version";Expression="svcUpdateVersion"}

}

Then,

Get-Content C:\hosts.txt | foreach {Get-IEVersion -computer $_}

Where hosts.txt has the server details..

OR

get-content c:\hosts | foreach {[system.diagnostics.fileversioninfo]::GetVersionInfo("\\$_\C`$\program files\internet explorer\iexplore.exe") }

Regards,

V.

Free Windows Admin Tool Kit Click here and download it now
February 6th, 2015 3:10am

Venu - that won't work.It only queries the local machine. 

Look in repository for a script that uses remote registry calls or use the WMI registry provider to remote the query.

February 6th, 2015 6:33pm

Try this:

#http://support.microsoft.com/kb/900935

Function Get-RemoteRegistryValue{
     Param(
          $computername=$env:computername,
          $key ='SOFTWARE\Microsoft\Windows NT\CurrentVersion',
          $valuename='CurrentBuild'
     )

     $reg=[Microsoft.Win32.RegistryKey]::OpenRemoteBaseKey('LocalMachine', $computername)
     $regKey=$reg.OpenSubKey($key)
     $regKey.GetValue($valuename)
}

Get-RemoteRegistryValue -computer somepc -key 'SOFTWARE\Microsoft\Internet Explorer' -ValueName Version


Free Windows Admin Tool Kit Click here and download it now
February 6th, 2015 6:38pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics