+ Reply to Thread
Results 1 to 2 of 2

VBA code doesn't work anymore (WinHttpReq)

  1. #1
    Registered User
    Join Date
    03-24-2014
    Location
    Vienna, Austria
    MS-Off Ver
    Excel 2010
    Posts
    72

    VBA code doesn't work anymore (WinHttpReq)

    Hi,

    I have a VBA code that used to work several months ago (getting an xls file from the internet), but now it doesn't.
    I get a runtime error 2147024891 ("Access denied") at line "WinHttpReq.Send".

    Anybody has an idea what could be wrong?
    I used to reinstall my Win 7 several weeks ago, maybe that has an influence?

    Thanks a lot Code is below.

    Please Login or Register  to view this content.

  2. #2
    Registered User
    Join Date
    03-24-2014
    Location
    Vienna, Austria
    MS-Off Ver
    Excel 2010
    Posts
    72

    Re: VBA code doesn't work anymore (WinHttpReq)

    Google ftw! Found the answer.

    I replaced
    Set WinHttpReq = CreateObject("Microsoft.XMLHTTP")
    by
    Set WinHttpReq = CreateObject("Msxml2.ServerXMLHTTP")

    well, still I would be interested, why my code used to work and now I had to change it?

    Thanks Maybe this helps someone.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Checbox doesn't work anymore
    By daanlachmeijer in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-16-2014, 09:30 AM
  2. macro doesn't work anymore
    By cat3appr in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-12-2014, 05:31 AM
  3. Script doesn't work anymore (auto hide rows and columns
    By Crispy85 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-02-2013, 02:17 AM
  4. Excel 2007 : Paste special doesn't work anymore
    By eva000 in forum Excel General
    Replies: 2
    Last Post: 03-23-2012, 09:14 AM
  5. [SOLVED] How do you get rid of a link that doesn't exist anymore?
    By esparzaone in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-24-2005, 01:06 PM

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