C# ON THE NET


Simple program to demonstarte the power of c# on the Net.This program require web server e.g(java web server ,apache etc).

Hello.cs
class zzz
{
public static void Main()
{
System.Console.WriteLine("Content-Type:text/html\n");
System.Console.WriteLine("<body bgcolor=blue>");
System.Console.WriteLine("<center><p><p>");
System.Console.WriteLine("<b>Hello to everyone.Its me Manish babbar<b>");
System.Console.WriteLine("</body>");
}
}

Compile the class Hello.cs .This will give u aexe file i.e Hello.exe.Put this file in the server's cgi-bin directory.for e.g if u have java server installed in C drive than the place toput the Hello.exe is c:/javawebserver/cgi-bin/" your file i.ehello.exe".

Copy the file Hello.exe to cgi-bin directory.now open the browser window and put the url http://localhost:8080/cgi-bin/Hello.execonsidering your server is running at 8080 port.

Most Commented Articles :

Twitter Digg Delicious Stumbleupon Technorati Facebook Email

No comments yet... Be the first to leave a reply!