Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access
| Search | Today's Posts | Mark Forums Read
Access Discussion of Microsoft Access database design and programming. See also the forums for Access ASP and Access VBA.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #11 (permalink)  
Old December 8th, 2005, 12:43 PM
Friend of Wrox
 
Join Date: Oct 2004
Location: Clinton, UT, USA.
Posts: 564
Thanks: 0
Thanked 4 Times in 4 Posts
Default

No Worries - I know how that goes.

Try the code below...
ocxBrowser is the name of the Browser Control

    strURL = "http://echovue.com/"
    Set objIE = Me.ocxBrowser.Object
    objIE.Navigate strURL

That should show you my home page in the window - and yes it needs to be updated!

You could probably just put that code on a button click, and then see if it runs.

Mike
EchoVue.com
  #12 (permalink)  
Old December 8th, 2005, 12:49 PM
Friend of Wrox
 
Join Date: Sep 2005
Location: , , USA.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Corey
Default

Thanks Mike

  #13 (permalink)  
Old December 8th, 2005, 01:03 PM
Friend of Wrox
 
Join Date: Sep 2005
Location: , , USA.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Corey
Default

Mike - I'm receiving an error message stating

Compile error:
Invalid outside procedure

I entered the code button click


Code below:
Option Compare Database

strURL = "http://echovue.com/"
Set objIE = Me.ocxBrowser.Object
objIE.Navigate strURL

End Sub


  #14 (permalink)  
Old December 8th, 2005, 01:52 PM
Friend of Wrox
 
Join Date: Sep 2005
Location: , , USA.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Corey
Default

Hey - I got your web sight to work. Thanks for the help.
Now I'm going to attempt to add the URL Checker - Any pointers?

Corey


  #15 (permalink)  
Old December 8th, 2005, 02:11 PM
Friend of Wrox
 
Join Date: Oct 2004
Location: Clinton, UT, USA.
Posts: 564
Thanks: 0
Thanked 4 Times in 4 Posts
Default

Sure, the sub below will be the key...

Private Sub ocxBrowser_DownloadComplete()
    On Error Resume Next
    strFileName = "C:\Source.txt"
    Set objIE = Me.ocxBrowser.Object
    Open strFileName For Output As #1
    Print #1, objIE.Document.body.innerHTML
    Close #1
    txtAddress = objIE.LocationURL
    Beep
End Sub

This saves the html code of the page to a file called Source.txt on your C:Drive.

There may be a better design, but I would set up a global integer called intCounter, and an Array containing the URL's that you would like to check.

When a button is pushed, or however else you would like to start it, set the Browser to the first URL. When the whole page is downloaded, it will run the sub above. Add some code in here that opens the files and checks to see if it is a "Page Not Found" page or something else. Do whatever event you need to like send yourself and email with the URL, pop up a MsgBox etc. When that is done, increment intCounter, and set the url of the browser to urlArray(intCounter). You will probably want to put an if statement that only does this if there are still URL's to check. Otherwise, have it give you a completed message or something.

I am headed out in a few minutes, but may be able to get you some more help if you need it.

Mike

Mike
EchoVue.com
  #16 (permalink)  
Old December 8th, 2005, 03:30 PM
Friend of Wrox
 
Join Date: Sep 2005
Location: , , USA.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Corey
Default

Ok, got it to work, thank you very much.

Can you let me know it you can help me with this one – It’s actual is that first related question?

I’m trying to find a way that I can get Microsoft access to check and verify live web links and dead from a list of URL’s I currently have in a table.
There are new web links added daily so I will need to check the links for frequently for any that aren’t valid or show the “The page cannot be found “ page.

Any help or direction would be greatly appreciated


  #17 (permalink)  
Old December 8th, 2005, 04:16 PM
Friend of Wrox
 
Join Date: Oct 2004
Location: Clinton, UT, USA.
Posts: 564
Thanks: 0
Thanked 4 Times in 4 Posts
Default

How big is your application? Perhaps we could collaborate over email and get it up and running for you.

Mike

Mike
EchoVue.com
  #18 (permalink)  
Old December 8th, 2005, 04:21 PM
Friend of Wrox
 
Join Date: Sep 2005
Location: , , USA.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Corey
Default

here are my e-mail's

cvlasak@hotmail.com
cvlasak@wssmedia.com





Similar Threads
Thread Thread Starter Forum Replies Last Post
URL Checker caster001 PHP How-To 1 November 27th, 2006 11:10 AM
Run Microsoft Access 2003 with runtime C_O Access 2 February 17th, 2006 01:36 PM
Problem Connecting to Microsoft Access Database eric_lim_1 Classic ASP Databases 1 September 17th, 2005 03:12 AM
Microsoft Access can't open the database because. vinodkalpaka Classic ASP Components 2 August 4th, 2004 06:27 PM
Microsoft Access can't open the database because. vinodkalpaka Classic ASP Databases 2 July 24th, 2004 04:37 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.