More Internet Exporer

Discussion in 'AutoCAD' started by Mike Warner, Jun 30, 2006.

  1. Mike Warner

    Mike Warner Guest

    Thanks to Matthew and Mayayana I can now open IE maximized - works
    great.

    As this is one of my first ventures into the world of the Windows API I

    still need some more help.


    Part of my application is the ability to view PDF files of
    manufacturer's catalogues.


    Now what I need to do is ensure that you cannot open multiple instances

    of the same page.


    The following is a typical call to open a web page. (Courtesy of
    Matthew)
    ---------------------------------------------------------------------------­------------

    Private Sub MnuBimba_Click()
    '********************************
    Dim objIE As Object
    Set objIE = CreateObject("InternetExplorer.Application")
    With objIE
    .navigate2 "http://www.bimba.com/products/products.htm"
    .MenuBar = False
    .StatusBar = False
    .ToolBar = False
    .Visible = True
    End With
    apiShowWindow objIE.hwnd, SW_SHOWMAXIMIZED
    End Sub
    ---------------------------------------------------------------------------­--

    How do I back out of this routine if the page is already open?


    Further to this, it is too easy to keep opening new pages - to the
    point where things become unmanageable.


    I can keep a track of the number of open pages but is there a method to

    programmatically close them.


    I've spent a considerable amount of time trying to solve this myself
    but I have reached the point where I must ask for help.
     
    Mike Warner, Jun 30, 2006
    #1
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.