有关登录代码设计…… 本帖最后由 Earl0 于 2009-10-31 22:40:37 编辑 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 try { if (CUser.checkUserLogin(txtName.Value, txtPwd.Value)) { string userID = CUser.GetUserID(txtName.Value, txtPwd.Value); // 增加session信息 this.Session["currentUserID"] = userID; string userType = CUser.GetUserID(txtName.Value, txtPwd.Value); if (userType.Equals("0")) { Response.Redirect("admin.aspx"); } else if (userType.Equals("1")) { Response.Redirect("admin1.aspx"); } else { Response.Redirect("user.aspx"); } } else { OConfig.AlertInfoWindow("您输入的用户名或者密码错误,请重新输入!", this); return; } } catch (Exception) { OConfig.AlertInfoWindow("系统登录失败,请重试!", this); } C#如何在word里写入上下标 用javascript可以获取服务器时间吗?怎么获取? datagridview如何排序 remoting TCP/IP如何限制客户端登录数 水晶报表有两个“详细资料”节怎么实现? 我想读取一个记事本,然后再该记事本最后一行内容加上一行内容,怎么做呢? [急!!]如何使winform中各控件中的状态恢复到初始状态? 怎么用C#实现WinXP任务栏上的地址栏? 求一个类 线程问题?来者有分。 请问下Base64图片编码 转换成图片的问题 请问如何将创建的 Bitmap 转成 String
{ if (CUser.checkUserLogin(txtName.Value, txtPwd.Value))
{
string userID = CUser.GetUserID(txtName.Value, txtPwd.Value);
// 增加session信息
this.Session["currentUserID"] = userID;
string userType = CUser.GetUserID(txtName.Value, txtPwd.Value);
if (userType.Equals("0"))
{
Response.Redirect("admin.aspx");
}
else if (userType.Equals("1"))
{
Response.Redirect("admin1.aspx");
}
else
{
Response.Redirect("user.aspx");
}
}
else
{
OConfig.AlertInfoWindow("您输入的用户名或者密码错误,请重新输入!", this);
return;
}
}
catch (Exception)
{
OConfig.AlertInfoWindow("系统登录失败,请重试!", this);
}