Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Shell to IE

Posted on 2006-11-01
2
Medium Priority
?
159 Views
Last Modified: 2010-04-30
I need to shell to IE within a VB app. Some caveats:

1) IE will not always be the default browser, so ShellExecute API will not always work.
2) The path to iexplore.exe may not always be in the environment PATH variable so SHELL("iexplorer.exe") may produce a file not found error.
3) Although more than likely so, I do not know if I can always count on iexplore.exe being in the directory C:\Program Files\Internet Explorer\ (not on C drive, not in the directory Internet Explorer...)

I do not want to initiate a search every time to find it. Is there a way (reading a specific registry key, etc.) that I can find it. Since it is such an integral part of M$ operating system, you whould think its location would be engraved in stone somewhere.

Doug
0
Comment
Question by:dbbishop
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 13

Accepted Solution

by:
jmundsack earned 1000 total points
ID: 17852683
Try this:

Public Sub Main()
    Dim oIE As Object
    Set oIE = CreateObject("InternetExplorer.Application")
    MsgBox oIE.Path
End Sub

HTH-Jon
0
 
LVL 15

Author Comment

by:dbbishop
ID: 17852758
I went ahead and used FullName property, with includes the path and the application name. Thanks!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question