+ Reply to Thread
Results 1 to 4 of 4

Download/Save webpage images to file using VBA

  1. #1
    Registered User
    Join Date
    06-04-2007
    MS-Off Ver
    Excel 2007
    Posts
    94

    Download/Save webpage images to file using VBA

    I had originally asked for a response to this question over at MrExcel Board, some days ago but the solution does not seem to fix the problem. I was hoping maybe someone here could shed some light on getting this macro to work.

    I tried using the following

    Please Login or Register  to view this content.
    to get these files which are listed in the A column in a new workbook with the sheet being Sheet1

    117427934569752sm
    117428128343967sm
    117428291462196sm
    117428380391871sm

    and the only thing that has ever showed up was a .jpg file with no name and with no preview.

    Is there something that I am missing to get this to work?

    UPDATE:
    Not sure what was going on but I took the above code and moved it from personal.xlsb into a separate workbook and voila it worked
    Please Login or Register  to view this content.
    Last edited by capnhud; 05-09-2012 at 09:42 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    05-21-2009
    Location
    Great Britain
    MS-Off Ver
    Excel 2003
    Posts
    550

    Re: Download/Save webpage images to file using VBA

    What value is URLDownloadToFile returning? See http://msdn.microsoft.com/en-us/libr...=VS.85%29.aspx.
    Post responsibly. Search for excelforum.com

  3. #3
    Registered User
    Join Date
    06-04-2007
    MS-Off Ver
    Excel 2007
    Posts
    94

    Re: Download/Save webpage images to file using VBA

    Quote Originally Posted by Chippy View Post
    What value is URLDownloadToFile returning? See http://msdn.microsoft.com/en-us/libr...=VS.85%29.aspx.
    Not sure how I could determine that. All I see is one .jpg in the download folder and that is it.

  4. #4
    Valued Forum Contributor
    Join Date
    05-21-2009
    Location
    Great Britain
    MS-Off Ver
    Excel 2003
    Posts
    550

    Re: Download/Save webpage images to file using VBA

    URLDownloadToFile is meant to be called as a function returning a value so that you (the code) can examine the value. Like this, but apply it to URLDownloadToFile:

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1