Winsock,VB & ASP 
Author Message
 Winsock,VB & ASP

Hi

I have a question regarding ASP and winsock. I've made an standard VB
application to retrive some information from a remote server using Winsock.
I'm now want a component om my web page that sends a string to a remote
server, and then display the result on the webpage.
I'm not to familuar to webclass programming, only made a few smaller dll
files before this project =/.
Now I dont know how to get winsock in my project.
Sound simple, but is it?
One component "onLoad" in a asp page that sends a string to a remote server
and then displays the result from the remote sevrer, in html, using
response.write.

This is the code I now have i VB6 (short sample):

Private WIthEvents objWinSock As MSWinsockLib.Winsock

Public Function WSKTest() As String
   Set objWinSock = New MSWinsockLib.Winsock
   WSKTest = "Done."
End Function

And a ASP File:
<%
 Dim obj
 Set obj = Server.CreateObject("project.class")
 response.write obj.WSKTest()
%>

In my webbrowser i get this response:

(0x800A01AD)
ActiveX component can't create object

Why cant my webserver create the winsock?

/Dennis



Mon, 27 Dec 2004 21:23:52 GMT  
 Winsock,VB & ASP
The Winsock cannot be used in an ASP page because it need a Container like a
VB form which can give it a Windows Handle on the other hand if you need the
response from the web server then this should be of help to you.

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmls...
m/xmobjxmlhttprequest.asp

make sure you have the MSXMLl parser installed.

--
Best Regards,

Trevor Benedict R
Microsoft Certified Professional



Fri, 31 Dec 2004 16:05:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Winsock, posting data from VB form to a ASP page

2. Programming VB & Winsock

3. Correction: VB, Access & Winsock programming

4. VB, Access & Winsock programming

5. VB & Winsock

6. Correction: VB, Access & Winsock programming

7. VB, Access & Winsock programming

8. Winsock & VB

9. VB 5.0 & Winsock control

10. vb.net & winsock

11. ASP & ASP.NET

12. VB & ASP

 

 
Powered by phpBB® Forum Software