doctor2001
IS-IT--Management
Hi -
I am adding a whois search to my website with the following code:
Dim tcpc As New TCPClient
tcpc.Connect("whois.networksolutions.com", 43)
Dim strDomain As [String] = txtDomain.Text + ControlChars.Cr + ControlChars.Lf
Dim arrDomain As [Byte]() = Encoding.ASCII.GetBytes(strDomain.ToCharArray())
Dim s As Stream = tcpc.GetStream()
s.Write(arrDomain, 0, strDomain.Length)
Dim sr As New StreamReader(tcpc.GetStream(), Encoding.ASCII)
While -1 <> sr.Peek()
txtResults.Text = CType(sr.ReadToEnd, String)
End While
tcpc.Close()
___________________________________________________________
This works fine...but all i really want to do is return a value (true or false) to see if the domain is avalible to register or not. I really don't need the owner, address, etc.
Does anyone know how this can be accomplished?
Thanks -John
I am adding a whois search to my website with the following code:
Dim tcpc As New TCPClient
tcpc.Connect("whois.networksolutions.com", 43)
Dim strDomain As [String] = txtDomain.Text + ControlChars.Cr + ControlChars.Lf
Dim arrDomain As [Byte]() = Encoding.ASCII.GetBytes(strDomain.ToCharArray())
Dim s As Stream = tcpc.GetStream()
s.Write(arrDomain, 0, strDomain.Length)
Dim sr As New StreamReader(tcpc.GetStream(), Encoding.ASCII)
While -1 <> sr.Peek()
txtResults.Text = CType(sr.ReadToEnd, String)
End While
tcpc.Close()
___________________________________________________________
This works fine...but all i really want to do is return a value (true or false) to see if the domain is avalible to register or not. I really don't need the owner, address, etc.
Does anyone know how this can be accomplished?
Thanks -John