如何检查用户名 [英] how to check username
本文介绍了如何检查用户名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何通过点击按钮来检查用户名?
它必须检查sql server中的数据库.
How to check the username by hitting a button?
It has to check a database in sql server.
How to write the codebehind code for that?
推荐答案
^ ]
http://www.dotnetspider.com/resources/7450-Check-Username-Exists-或否 [^ ]
http://forums.asp.net/t/1567065.aspx?UserName+exist+in+database+or+not%3F[^]
http://www.dotnetspider.com/resources/7450-Check-Username-Exists-or-Not[^]
string struname = txtusername.Text;
ds = new DataSet();
ada = new SqlDataAdapter("SELECT username FROM DBFile WHERE id ="+userid, con);
ada.Fill(ds, "DBFile");
这篇关于如何检查用户名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文