Home  |  Index  |  Dotnet4all Snippets  |  Submit resources
About  |  Mail us  
Dotnet4all Logo

  Socket connection in a web app? (Monday, January 02, 2006)




Found the following interesting discussion in the Newsgroups:

Socket connection in a web app?
by:Martin

I am a .Net newbie. I have Visual Studio.Net 2003 and have the luxury
of being able to do some R&D/learning in a non-production environment.

I want to develop a web application that will get the data that it
serves out from two sources: (1) a database (probably MS Access but
could be SQL Server) and (2) directly from another application running
on the same machine. (BTW, this is on an intranet - the server will be
dedicated to these apps only).

I would like to have the web app and the "other" app talk to one
another using a socket connection. (The "other" app will be written in
VB6 and I'm very familiar with Winsocket communications from that
side).

I understand that there is a socket class available in .Net but that's
the limit of my knowledge. Can I use this to communicate with my
would show the use of the socket class in a web app that I could
adapt/ learn from?

Thanks for any guidance.

Martin


 Reply:
by:Cor Ligthert

 Hi Martin,

Did you already looked in the VB.net resource kit.
I thought that I had seen some samples which answers to your questions.

VB.net Resource kit
http://msdn.microsoft.com/vbasic/vbrkit/default.aspx

And if you have problems installing the resource kit
http://msdn.microsoft.com/vbasic/vbrkit/faq/#installvdir

And as advice, do not forget to look at webservice what maybe can give as
well a solution for you.

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vsintro7/html/vbwlkCreatingDistributedWebApplicationWalkthrough.asp

I hope this helps?

Cor



 Reply:
by:Martin

 Yes, I have the resource kit installed. What I found in there
regarding sockets was for a Windows App. I'm assuming that using a
socket in a Web App would be different, no?


 Reply:
by:Cor Ligthert

 Hi Martin,

After this message I get maybe a better idea what you are after.
Having a connection to a userkind browser and a windows application can be
difficult, however not when you implement of course your own webbrowser,
than there are again other possibilities.

I give you two links, one is to the webbroswer the other to all ristrictions
that will be made to prevent that IE talks with a workstation. (There is
also a kind of interop possible with IE, and than you have to use shdocvw
instead of axshdocvw and because this is not a real net control probably as
well using VB6, which I do not know).

Webbrowser
http://support.microsoft.com/?kbid=311303

Some faqs
http://support.microsoft.com/default.aspx?scid=kb;EN-US;311284

mshtml
http://msdn.microsoft.com/library/default.asp?url=/workshop/browser/hosting/hosting.asp

This is what goes happen with IE without interop.

http://msdn.microsoft.com/security/default.aspx?pull=/library/en-us/dnwxp/html/xpsp2websites.asp

I hope this gives again some idea's

Cor








0 Comments:

Post a Comment

 
Previous Posts
    - Quick Tutorial - VB6 to .NET
    - Moving between forms in VB.NET
    - Is form closed?
    - Determine if property exists at runtime?
    - How to convert VB6 Type To .NET Structure
    - How to create a suimple virtual directory with def...
    - Multi column listboxes
    - Unicode to MS-DOS Cyrilic (code page 866)
    - Vb.net 2003 Get Text File
    - Program upgrades

Archives
    - 10/03/2004 - 10/10/2004
    - 10/10/2004 - 10/17/2004
    - 10/17/2004 - 10/24/2004
    - 10/24/2004 - 10/31/2004
    - 10/31/2004 - 11/07/2004
    - 11/21/2004 - 11/28/2004
    - 11/28/2004 - 12/05/2004
    - 12/05/2004 - 12/12/2004
    - 12/12/2004 - 12/19/2004
    - 12/19/2004 - 12/26/2004
    - 12/26/2004 - 01/02/2005
    - 01/23/2005 - 01/30/2005
    - 01/01/2006 - 01/08/2006
    - 09/24/2006 - 10/01/2006

Disclaimer & Terms of Use  | DotNet4All.Com concept & © 2004 - 2007 by  Zelders²  - Holland