0

I am running windows 8 IIS 8.5. The following two lines of code generate a error response. I would like to note that the code works just fine when ran as a .vbs script locally. The only thing i had to remove was the Server. and just do a CreateObject which i also tried via Classic ASP/IIS to no avail.

Code:

Dim oXMLHTTP
Set oXMLHTTP = Server.CreateObject("Msxml2.ServerXMLHTTP.6.0")

Response:

Microsoft VBScript runtime error '800a01a8'
Object required: ''

user692942
  • 16,398
  • 7
  • 76
  • 175
Tim Wiley
  • 21
  • 3
  • What line does the error occur on? I doubt it is one of those lines. – user692942 Oct 31 '17 at 20:17
  • Those 2 lines are the only lines. I removed everything else to see what was causing the error. Again if i save this exactly as a .vbs file it works and i can actually get a web page with the additional code. From the very dated tidbits i read this issue may/may not be related to some permissions somewhere that IIS has to the path/folder of the Msxml DLL file but i have tried granting excessive privileges to all the paths i can find to no avail. – Tim Wiley Oct 31 '17 at 21:30
  • A downvote for a question that is littered all over the internet without many solutions?? Seriously?? Stack is just becoming too pompous for me. – Tim Wiley Oct 31 '17 at 21:36
  • Resolved - came down to going thru all the DLL's and making sure they were register and IIS had permission to the folders/files as well as permission to read the class registry entries. Look closer next time @Lankymart – Tim Wiley Oct 31 '17 at 21:45
  • Sorry but you need to write a better question next time. Would have been better if you had posted more code rather then these two lines and that isn’t the usual error you get with failure to create COM references in VBScript. Permissions is always a go to but then there is architecture as well, is this running 32 bit versus 64 bit etc. The detail just isn’t there, so what you consider pompous I consider inability to coherently put a problem across. – user692942 Oct 31 '17 at 22:28
  • I [wrote](https://stackoverflow.com/a/35985827/692942) about COM creation and things to check while ago, but most of it is related to failure to create object errors which this isn’t. Glad you managed to work through it and find a solution. – user692942 Oct 31 '17 at 22:35
  • @lankymart - Well next time i will add excess code to the 2 lines creating the problem... LMAO ... what a joke. – Tim Wiley Oct 31 '17 at 22:46
  • and i literally posted everything... the exact code, the exact response... gave my environment info. I think somebody just go frustrated when a 2 line problem had them perplexed. – Tim Wiley Oct 31 '17 at 22:48
  • No someone got frustrated with the same &@£# being posted day in day out. It’s fine I’ll avoid you in future, in the 20+ years in the tech industry I've probably asked 6 questions on this site and a handful of times on forums. People just see [so] as an easy option even having the attitude that they are entitled to an answer. That just annoys me if I’m honest, rant over. I’m done. – user692942 Oct 31 '17 at 22:53
  • https://meta.stackoverflow.com/q/357951/692942 – user692942 Oct 31 '17 at 23:04
  • @lankmart - well i have you by 6 years... been coding since i was 9 years old in nearly a dozen different languages. I've had to manage database systems that have over a billion rows of data in one table. So lets be real clear your pompous "I doubt those two lines are the problem" when they are and then a down vote is BS. It was a very clear question... and this same asp question with variation is all over Stack most without answers. This error message is all over the web as well with very little response. ASP is old and cranky but that doesn't mean you need to be to. – Tim Wiley Oct 31 '17 at 23:13
  • Lets be absolutely clear, you're the one being "cranky". I offered some advice, to which you replied in a hostile manner. An Object Required error is [usually due to referencing a variable as an object variable when it is not](https://stackoverflow.com/q/23633643/692942), that is why I questioned whether those two lines were the cause. – user692942 Nov 01 '17 at 00:49
  • Cranky = "What line does the error occur on? I doubt it is one of those lines" followed by an immediate down vote for no good reason. I mean it was 2 lines of code and you didn't have any answers... So it must not have been that easy huh... Captain Cranky Pants – Tim Wiley Nov 01 '17 at 01:04
  • Did I not just explain what commonly an "Object Required" error is related to? – user692942 Nov 01 '17 at 01:54
  • You didn't explain a thing until i solved the problem myself. The only thing you did was express doubt about the 2 lines of code and downgrade the question. You didn't do a thing. I've been in the industry 26 years and in this field there is never a reason to be condescending to someone asking a question even thought you may live and breath here on Stack most of us don't. – Tim Wiley Nov 01 '17 at 02:42
  • Just wanted more information, but you worked through it and fixed it anyway. So to make this question useful after all, please consider leaving an answer and explaining what you did to fix the error. See [Can I answer my own question?](https://stackoverflow.com/help/self-answer). – user692942 Nov 01 '17 at 12:09

1 Answers1

1

I'm not exactly which one of these steps resolved the issue as i did not pause between each one but one of them resolved it. FYI i was convinced that because those two lines worked just fine in .vbs script that it had to be something btw IIS and permissions to registry/files/folders related to the DLL involved.

Step 1. Searched the registry for the Object name. In this case "Msxml2.ServerXMLHTTP.6.0"

Step 2. For all registry entries i took ownership of the parent registry folders so i could give read access to IIS user account(s).

Step 3. Using the physical file paths for the the DLL found when executing step #1. I went and made sure the files/folders had read/execute permission for the IIS user account(s).

Step 4. Registered the DLL at the command line for good measure.

Step 5. Rebooted because restarting IIS didn't seem to do it.
* After reboot problem resolved and i was able to continue to add code and use the object effectively*

Tim Wiley
  • 21
  • 3
  • Thanks for posting. – user692942 Nov 01 '17 at 14:52
  • 1
    No prob Lankymart - I come from your time too where there was no web, no google, and you were limited to as many huge books that you could carry in your bag or afford to buy that didn't have all nearly the answers but might help you deduce or derive an approach with creativity... So believe me I'm no one who has lived on easy answers and cut paste of those who have sweated... So i feel you on that.. – Tim Wiley Nov 01 '17 at 16:07