Link to home
Start Free TrialLog in
Avatar of Andrew Angell
Andrew AngellFlag for United States of America

asked on

Invalid Procedure Call when saving a file...but only on this one particular item...????

I'm posting items to eBay and I'm saving a copy of the XML request and response to the server.  We've been using this application for months without any problems at all.

I got an email from an eBay poster here that they're getting an Invalid Procedure Call when trying to post an item.  The code this error is happening on is as follows:

'Write contents of the response to a file on the server
      set fs=Server.CreateObject("Scripting.FileSystemObject")
            AddItemResponseXML = (Server.MapPath("../xml/eBay/AddItemResponse_" & FMItemNumber & ".xml"))
            set tfile=fs.CreateTextFile(AddItemResponseXML)
                  tfile.WriteLine(AddItemResponse)
                  tfile.close
            set tfile=nothing
      set fs=nothing

The actual line it's happening on is

tfile.WriteLine(AddItemResponse)

So it's happening when trying to write the XML data into the new txt file.  What's weird is if I comment out this saving of the request file and run the script it posts the item just fine.  All other items have always and are still posting just fine.

So now here's the ONLY thing I can possibly think might be causing this problem.  The particular item that isn't working....Microsoft software.  Could it possibly be that the word Microsoft inside the XML data is somehow getting screwed up with the ASP code since it sometimes uses Microsoft.ObjectName or something like that????

I can't think of any other reason this would be happening with these items, but even if that is the problem I can't think of how to fix it.

Any ideas or information on this would be greatly appreciated.  Thanks!
ASKER CERTIFIED SOLUTION
Avatar of Emad Gawai
Emad Gawai
Flag of United Arab Emirates image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial