Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can I obtain the actual version of Internet Explorer? 2

Status
Not open for further replies.

GVF

Programmer
Feb 25, 2005
160
US
Using "...weboptions.targetbrowser" seems to return the setting that Excel uses when saving-as-a-webpage. I need to determine the actual version of IE that is installed on the machine. Later versions of IE will block ActiveX controls. I can unblock the control (MSCOMM32.OCX) from within VBA but if the IE version is 5 or earlier the "compatibility flag" registry key doesn't exist and an error is generated bringing up a dire warning dialog. So what I want to do is:
If IE_Version > 5 then Call EnableMSComm
 
here's one way that avoids API calls:

Dim ieVersion As String
ieVersion = CreateObject("wscript.shell").RegRead("HKLM\SOFTWARE\Microsoft\Internet Explorer\Version")
 
That'll work. Thank you very much.

Greg
 
Didn't know that; .RegRead could come in handy

(worth a star)

sam
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top