Domanda

I want to write a script on windows using WSH jscript to be compiled by jsc.

I want the script to act as a very simple tcp server, listening to any port specified, and sending a text string upon receiving any request.

I have found some implementations which depend on a library that seems to only be available on windows machines with developer software installed. I need an implementation that can work on any windows machine (with .NET installed). I am happy to include a dll if there is one that can help to listen on tcp sockets.

Is there a suitable dll to act as a tcp server?

Is there a tcp server implementation in jscript that can be compiled with jsc?

È stato utile?

Soluzione

It sounds like you're talking about JScript.NET, which is separate from WSH. Since JScript.NET is a CLR language, you can use any of the available .NET Framework classes. Your best bet may be to find an example of a TCP server written in C# or VB.Net and then convert the code to JScript.NET.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top