Home | Contact Us | Download | Support | Purchase | Products


Product List
 
  "Hi Dave. Congratulations on the fantastic work on aspNetEmail. We've launched hundreds of thousands of email over the past couple of weeks with aspNetEmail, and we are totally impressed by your product. It is blazingly fast, and it handles errors very gracefully. My team couldn't have asked for a better product."
J.H.
 
More
Testimonies

Whois Query using Events

The following example demonstrates how to perform a Whois query using the event driven model.

[C#]

 using System;
 using aspNetWhois;
 namespace ConsoleApplication1
 {
 	class Class1
 	{
 		[STAThread]
 		static void Main(string[] args)
 		{
 			
 			Whois w = new Whois( "microsoft.com", "whois.networksolutions.com" );
 			w.QueryEvent += new QueryEventHandler( Whois_OnQuery );
 			w.Query();
 
 
 			Console.WriteLine( "done" );
 			Console.ReadLine();
 		}
 
 		static void Whois_OnQuery( object sender, QueryEventArgs e )
 		{
 			Console.WriteLine( "Sever: " + e.Server );
 			Console.WriteLine( "DomainName: " + e.DomainName );
 			Console.WriteLine( e.Results );
 		}
 
 	}
 }



[VB.NET]

Imports aspNetWhois
Module Module1

    Sub Main()
        Dim w As New Whois("microsoft.com", "whois.networksolutions.com")
        AddHandler w.QueryEvent, AddressOf Whois_OnQuery
        w.Query()


        Console.WriteLine("done")
        Console.ReadLine()
    End Sub


    Sub Whois_OnQuery(ByVal sender As Object, ByVal e As QueryEventArgs)
        Console.WriteLine(("Sever: " + e.Server))
        Console.WriteLine(("DomainName: " + e.DomainName))
        Console.WriteLine(e.Results)
    End Sub 'Whois_OnQuery

End Module







The box is not shipped. aspNetWhois is a downloadable product.