+ Reply to Thread
Results 1 to 25 of 25

Run-time error '5': Invalid procedure call or argument

Hybrid View

  1. #1
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Am getting error Run-time error '5': Invalid procedure call or argument. please help

    What happens if you load up internet explorer (or another web browser) and try and access one of the sites in your sample? Try:
    http://miami.craigslist.org/brw/pts/3949953392.html
    I'm thinking that as the code worked on one machine but not when you changed systems that maybe you have restricted web usage or the links are now dead.


    What happens if you run this code:
    Sub test()
    Dim rng, lr As Long, a, res As String, x As Long
    lr = Cells(Rows.Count, 1).End(xlUp).Row
    rng = Range("a2:b" & lr)
    x = LBound(rng)
    With CreateObject("MSXML2.XMLHTTP")
        .Open "GET", rng(x, 1), False
        .setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
        .send rng(x, 1)
        MsgBox .responsetext
    End With
    Range("a2:b" & lr) = rng
    End Sub
    Do you get a messagebox? What does it say?
    Last edited by ragulduy; 07-29-2013 at 10:23 AM.

  2. #2
    Registered User
    Join Date
    12-11-2012
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    20

    Re: Am getting error Run-time error '5': Invalid procedure call or argument. please help

    When I do it manually, am able to do it and all these links are from the past week, all links are live and fine. Am just not able to figure out how I did it last time. I am very sure that it was a button which i used with this code. all I had to do was to copy the links approximately 800 to 1000 links at a time, and then enter the button. It would fetch the description from each link in the next column. Am such numb skull, not able to figure out.

+ 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. Macro Run Time error - Invalid procedure call or argument
    By clundeen in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-01-2011, 01:59 AM
  2. Macro Error - Invalid Procedure Call or Argument
    By mcordi in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-12-2011, 05:40 PM
  3. Invalid procedure call or argument error
    By Patrick Simonds in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-12-2006, 06:45 PM
  4. [SOLVED] Run-time error '5': Invalid Procedure Call or Argument
    By Nikila in forum Excel General
    Replies: 2
    Last Post: 02-24-2006, 05:30 PM
  5. Run Time Error 5 - Invalid Procedure Call or Argument Q
    By John in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-26-2005, 05:05 PM

Tags for this Thread

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