没有合适的资源?快使用搜索试试~ 我知道了~
c# 与数据库相连后 如何实现用户注册的功能
5星 · 超过95%的资源 需积分: 10 77 下载量 111 浏览量
2011-10-10
22:30:55
上传
评论
收藏 2KB TXT 举报
温馨提示
试读
3页
c# 与数据库相连后 如何实现用户注册的功能
资源推荐
资源详情
资源评论
using System.Data;
using System.Data.SqlClient;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using blog.util;
public partial class hy_login : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void button_jcyh(object sender, EventArgs e)
{
string str = hy_count.Text;
string sqlstr = "select count(*) from hy where hy_count="+str+"";
Response.Write(sqlstr);
int myread = Convert.ToInt32( DataPublic.ExecuteScalar(sqlstr));
if (myread==0)
{
//Response.Write("帐号已存在,请重写帐号名!");
Response.Write("<script>alert(\"帐号已存在,请重写帐号名!!\");</script>");
}
else
using System.Data.SqlClient;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using blog.util;
public partial class hy_login : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void button_jcyh(object sender, EventArgs e)
{
string str = hy_count.Text;
string sqlstr = "select count(*) from hy where hy_count="+str+"";
Response.Write(sqlstr);
int myread = Convert.ToInt32( DataPublic.ExecuteScalar(sqlstr));
if (myread==0)
{
//Response.Write("帐号已存在,请重写帐号名!");
Response.Write("<script>alert(\"帐号已存在,请重写帐号名!!\");</script>");
}
else
资源评论
- 龙龙醉2013-09-21还是很不错的
- qw100235642013-03-27新人用起来还是不怎么懂···
- 大瓶冰红茶2013-06-07还是挺不错的。。
- onlyzm2014-04-28还可以。有点参考价值
bailixiao1983
- 粉丝: 0
- 资源: 3
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功