Re: Copying file down from web to a local directory

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Steven Burn (pvt_at_noyb.com)
Date: 09/29/04


Date: Wed, 29 Sep 2004 18:06:48 +0100

Forget trying to use IE and see here;

http://aspfaq.com/show.asp?id=2173

--
Regards
Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk
Keeping it FREE!
"Jeff Knecht" <heffizzle@msn.com> wrote in message
news:0cde01c4a644$ab14cab0$a401280a@phx.gbl...
> Okay, n00b question here.  Sorry if it isn't the most
> intelligent question out there. :-P
>
> I am trying to copy down a jpg image from the Mt. St.
> Helens webcam every 5 minutes to a local directory.
> Consider the following code:
>
> x=0
>
> Do While x <> 1
>    set objIE = CreateObject
> ("InternetExplorer.Application")
>    objIE.visible=false
>    objIE.navigate2
> ("http://www.fs.fed.us/gpnf/volcanocams/msh/images/mshvolc
> anocam.jpg")
>    Do While objIE.busy=True
>       wscript.sleep 60
>    Loop
>    call objIE.document.execwb
> ("saveas",2,"C:\volcano\mshvolcanocam.jpg")
>    objIE.Quit
>    Wscript.Sleep 300000
> Loop
>
> This code errors out with:
>
> C:\Documents and Settings\jeffok\Desktop\helens.vbs(10,
> 4) Microsoft VBScript runtime error: Object doesn't
> support this property or method: 'objIE.document.execwb'
>
> To me it looks like IE doesn't have an object
> named 'document', but I looked it up on MSDN and actually
> found it.  My guess is, i'm misunderstanding how this
> object is used and using it in the wrong context.  Of
> course, i'm not sure.
>
> I would appreciate somebody setting me straight in my
> ways.
>
> Thanks!
>
> -Jeff


Relevant Pages

  • Copying file down from web to a local directory
    ... Okay, n00b question here. ... I am trying to copy down a jpg image from the Mt. ... This code errors out with: ... Microsoft VBScript runtime error: ...
    (microsoft.public.scripting.vbscript)
  • Re: Return all files modified within the day???
    ... > Microsoft VBScript runtime error '800a01a8' ...
    (microsoft.public.inetserver.indexserver)
  • Re: zip files
    ... same error:(Microsoft VBScript runtime error: Subscript out of range: 'i') ... > Just decrement the counter before the "Do" loop and it will work, ... > ReadLineTextFile = CheckFile.ReadLine ...
    (microsoft.public.scripting.vbscript)
  • Re: Object Variable not set error
    ... "Erica" wrote in message ... > Microsoft VBScript runtime error '800a005b' ...
    (microsoft.public.scripting.vbscript)
  • RE: Recursive function help
    ... You could use a single query and return all employees sorted in to levels and use nested do while loops or a recursive function. ... > Microsoft VBScript runtime error '800a01fb' ... > Function GetParents() ...
    (microsoft.public.inetserver.asp.general)