Asp - INET control Webserver 2008

This line on an asp page on webserver 2008 errors out:
Set inet = Server.CreateObject("InetCtls.Inet")


Server object error 'ASP 0177 : 800401f3'

Server.CreateObject Failed

This page is works on a development box.
I think it's because I have Visual Studio installed.

I've tried this :
http://support.microsoft.com/default.aspx?scid=kb;en-us;159923
"License Package Authoring Tool"
But it's still not working.
That tool refers to using it for ActiveX controls put on a page with an <object> tag.

As you can see, I'm just doing a server.createobject.
not embedding an <object>
wininet.dll is on the machine.

Anybody have and idea why this won't load?
Thanks




awalkintheparkAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Gary DavisDir Internet SvcsCommented:
Why not use the more-current msxml.XmlHttpReqeust object with your classic Asp code?
0
awalkintheparkAuthor Commented:
I'm using the INET  to retrieve an HTML page into a string variable, used later in the page.
Do you have an example of msxml.XmlHttpReqeust used this way?
I looked around , haven't found one yet.

here's what I'm doing now:
inet.Url = url
stringvariable = inet.OpenURL()
then other things happen to the string

Thanks
0
awalkintheparkAuthor Commented:
Using msxml.XmlHttpReqeust :

Dim xmlhttp
Set xmlhttp =Server.CreateObject("Msxml2.XMLHTTP")

xmlhttp.open "GET", url,true
stringvariable = xmlhttp.responseText

generates this:
msxml3.dll error '8000000a'

The data necessary to complete this operation is not yet available.

Is there some timing issue on when it completes its request before the responseText is available?

xmlhttp.open "GET", url,true
--> Something else has to happen here?
stringvariable = xmlhttp.responseText

0
The 7 Worst Nightmares of a Sysadmin

Fear not! To defend your business’ IT systems we’re going to shine a light on the seven most sinister terrors that haunt sysadmins. That way you can be sure there’s nothing in your stack waiting to go bump in the night.

awalkintheparkAuthor Commented:
I don't know how to
What an equivalent in VBscript for this would be:

xmlhttp.onreadystatechange = function () {
   if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
         // Data is available now
         DoSomethingUseful(xmlhttp.responseText);
      }
   }
}
xmlhttp.send();

On the other hand, I know the INET control works.
And it's  2 lines to get the job done when the thing can be loaded.

The solution to loading then INET dll would be nice,
or a working example in VBscript that uses Msxml2.XMLHTTP
to request a URL and has xmlhttp.responseText available.



0
Gary DavisDir Internet SvcsCommented:
This is what I use. No need for onreadystatechange - this is synchronous and on the server, not the client.
 

Set objWinHttp = Server.CreateObject("Msxml2.ServerXMLHTTP.3.0")
objWinHttp.Open "POST", Url, False
objWinHttp.setRequestHeader "Content-Type", "text/namevalue"
objWinHttp.Send PostData ' *********** POST data ***********
transResponse = objWinHttp.ResponseText ' Get the response.

Open in new window

0
awalkintheparkAuthor Commented:
I'm do a "GET" from my server side script.
You are doing a POST.  
Also ,  in your example what is  PostData?
Would that be form data or something you are sending to the server?



0
awalkintheparkAuthor Commented:
For the record, and to save the next guy some time  the working code is at the end of this posting.
. I think one key was setting the 3 parameter in  .open to false.
It's otherwise very awkward to build an equivalent in Vbscript to this javescript code that is in use in all examples I found:  

xmlhttp.onreadystatechange = function () {
   if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
         // Data is available now
         DoSomethingUseful(xmlhttp.responseText);
      }
   }
}

Object model here:
http://msdn.microsoft.com/en-us/library/ms535874%28VS.85%29.aspx

.open just sets parameters, though the method name implies it's going to open..
Requires that you  .send to execute.

This woks:
xmlhttp.open "GET", url,false
xmlhttp.send
myStringVar  = xmlhttp.ResponseText ' Get the response.
0
Gary DavisDir Internet SvcsCommented:
Just change POST to GET. Remove the PostData.
PostData for POST is a string variable containing the form keywords and values separated by ampersands like "product=shirt&color=light+green". For GET, you would simply put the parameters in the Url's QueryString.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP

From novice to tech pro — start learning today.