Re: programmatically capture web page as internet archive (MHT)

From: ljb (.)
Date: 05/13/04


Date: Thu, 13 May 2004 07:55:44 -0500


"Michael Harris (MVP)" <mikhar at mvps dot org> wrote in message
news:%23klRjrIOEHA.3452@TK2MSFTNGP10.phx.gbl...
> > We have some ASP pages on the corporate intranet that report various
> > business statistics. We would like to capture a snapshot of these
> > reports each night about midnight by running a scheduled script.
> >
> > We've been unsuccessful at finding any examples of how a script can
> > capture a web page, preferably to an internet archive file (MHT).
> >
> > We've been able to build a kludge using Word VBA to generate an HTML
> > file, but it requires some cleanup after capture. We were hoping for
> > something that might do the equivalent of IE's File>Save As>Web
> > Archive, but from script.
>
>
> url = "http://www.yahoo.com"
> path = "c:\_temp\yahoo.mht"
> Const wdFormatWebArchive = 9
> set word = createobject("word.application")
> set doc = word.documents.open(url)
> doc.saveas path,wdFormatWebArchive
> doc.close
> word.quit
>

What version of Word or Office supports saveas wdFormatWebArchive? I don't
even find it on MSDN.

thanks
LJB



Relevant Pages

  • Re: programmatically capture web page as internet archive (MHT)
    ... > set stream = message.GetStream ... >> We have some ASP pages on the corporate intranet that report various ... We would like to capture a snapshot of these ... >> each night about midnight by running a scheduled script. ...
    (microsoft.public.scripting.wsh)
  • Re: programmatically capture web page as internet archive (MHT)
    ... > We have some ASP pages on the corporate intranet that report various ... > reports each night about midnight by running a scheduled script. ... > capture a web page, preferably to an internet archive file. ... Server side Office automation is neither recommended nor ...
    (microsoft.public.scripting.wsh)
  • programmatically capture web page as internet archive (MHT)
    ... We have some ASP pages on the corporate intranet that report various ... We've been unsuccessful at finding any examples of how a script can capture ... preferably to an internet archive file. ...
    (microsoft.public.scripting.wsh)
  • Re: programmatically capture web page as internet archive (MHT)
    ... capture the page as it looked, that is, with all the linked images. ... > returned by the Open method. ... >> We have some ASP pages on the corporate intranet that report various ... >> each night about midnight by running a scheduled script. ...
    (microsoft.public.scripting.wsh)
  • Re: Removing Rows for Printing
    ... One is to clear a sheet of all input cells leaving ... .PrintOut ' for testing use .PrintPreview ... I attached the script to the Print Button. ... I hid the Report worksheet. ...
    (microsoft.public.excel.worksheet.functions)