I cant set validation for existing Username when submit a registration form

I cant set validation for existing Username when submit a registration form

am 24.04.2006 15:08:03 von Chris Wu

<%

strODBC = "DSN=mysql_dsn; UID=root; PWD=;"

dim nama, syarikat, alamat1, alamat2
dim zip, negeri, negera, telefonP
dim telefonB, fax, emel, id
dim katalaluan1, sta, soalan, jawapan

nama = request.form("dNa")
syarikat = request.form("dSy")
alamat1 = request.form("dA1")
alamat2 = request.form("dA2")
zip = request.form("dZip")
bandar = request.form("dBand")
negeri = request.form("dNe")
negara = request.form("dNeg")
telefonP = request.form("dTP")
telefonB = request.form("dTB")
fax = request.form("dF")
emel = request.form("dE")
id = request.form("dNId")
katalaluan1 = request.form("dKat1")
sta = request.form("status")
soalan = request.form("dSoa")
jawapan = request.form("dJa")

Dim Objrs
Set Objrs = Server.CreateObject("ADODB.Recordset")

Dim Strsql
Strsql = "SELECT * FROM pendaftaran WHERE dNId = '" & id & "'"
Objrs.Open Strsql, strODBC, 1, 3

If Objrs.eof then
Set Objrs = Nothing
Set strODBC = Nothing
Response.redirect"Pendaftaran.asp?Message=!! Minta Maaf...Nama Id
Anda Telah Didaftar Oleh Ahli Lain!!"

Else

Objrs.AddNew
Objrs("dNa") = nama
Objrs("dSy") = syarikat
Objrs("dA1") = alamat1
Objrs("dA2") = alamat2
Objrs("dZip") = zip
Objrs("dBand") = bandar
Objrs("dNe") = negeri
Objrs("dNeg") = negara
Objrs("dTP") = telefonP
Objrs("dTB") = telefonB
Objrs("dF") = fax
Objrs("dE") = emel
Objrs("dNId") = id
Objrs("dKat1") = katalaluan1
Objrs("status") = stat
Objrs("dSoa") = soalan
Objrs("dJa") = jawapan
Objrs.Update
' ::::: Removing Recordset & Connection Object
Set Objrs = Nothing
Set strODBC = Nothing
Response.redirect"MainPage.asp?Message=Anda telah berjaya daftar diri
sebagai ahli"

End If

%>

*** Sent via Developersdex http://www.developersdex.com ***