Results 1 to 7 of 7

Thread: internet explorer

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2006
    Location
    Greater Manchester, UK
    Posts
    476

    internet explorer

    i was given the start of the code to disable the google website from being viewed in internet explorer: (as a test)
    VB Code:
    1. Option Explicit
    2. Dim IE As InternetExplorer
    3. Dim shWin As New ShellWindows
    4. Dim strURL As String
    5. Private Sub Form_Load()
    6. For Each iebrowser In shWin
    7.     strURL = iebrowser.locationurl
    8.     Debug.Print iebrowser.locationurl
    9.     Do While InStr(strURL, "Local%20Settings/Temporary%20Internet%20Files") = 46
    10.         strHTML = Replace(iebrowser.Document.Body.innerhtml, """", "")
    11. End Sub
    12.  
    13. If iebrowser.locationurl = "http:\\google.co.uk" Then
    14. MsgBox "no"

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: internet explorer

    What is the question?

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2006
    Location
    Greater Manchester, UK
    Posts
    476

    Re: internet explorer

    oh yea i forgot sorry!

    The code dosent work does any one know how to make it stop pages from being loaded, end product will stop violent sites and porn from being accesed, by blocking the url. my test is to block google.

    thanks in advance

  4. #4
    I'm about to be a PowerPoster!
    Join Date
    Jan 2005
    Location
    Everywhere
    Posts
    13,647

    Re: internet explorer

    It's http:// not \\.

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2006
    Location
    Greater Manchester, UK
    Posts
    476

    Re: internet explorer

    it is something to do with :

    Dim IE As InternetExplorer

  6. #6
    I'm about to be a PowerPoster!
    Join Date
    Jan 2005
    Location
    Everywhere
    Posts
    13,647

    Re: internet explorer

    Have you added a reference to the Internet Explorer automation library?

  7. #7

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2006
    Location
    Greater Manchester, UK
    Posts
    476

    Re: internet explorer

    no, is that in components, i got given the code and he said it would work

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width