上机实习报告总结结尾
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
上机实习报告总结结尾
一. 首页
代码如下;
using System;
using ;
using ;
using ;
using ;
using ;
using ;
namespace WindowsApplication1
{
public partial class Form5 : Form {
public Form5()
{
InitializeComponent();
}
private void button1_Click(object sender, { logo from = new logo();
(); EventArgs e)
}
private void button2_Click(object sender,
EventArgs e) {
Form2 from = new Form2();
();
}
private void button3_Click(object sender, EventArgs e)http:///shijuan/ 试卷 {
Form3 from = new Form3();
();
}
private void button4_Click(object sender, EventArgs e) {
Form4 from = new Form4();
();
}
}
}
二. 登录模块
代码如下:
using System;
using ;
using ;
using ;
using
;
using ;
using ;
using ;
namespace WindowsApplication1
{
public partial class logo : Form
{
public logo()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
}
private void button1_Click(object sender, EventArgs e) {
string connstring = @"Data Source=panlunzhao;Initial Catalog=;Integrated Security=True";
SqlConnection conn = new SqlConnection(connstring); ();
string username = (); string password = (); SqlCommand comm = ();
= "select * from manage where username='" + username + "' and password='" + password + "'";
SqlDataReader sqlda = ();
if (())
{
ifhttp:///gongzuobaogao/ 工作报告(sqlda.ToString().Trim() == password) {
//("恭喜您登陆成功!", "登陆成功!", , );
//Form2 f = new Form2();
//();
Form3 from = new Form3();
();
}
else { ("密码错误,请重新输入!", "错误
", , ); }
}
else { ("此用户不存在,请您注册!", "注册", , ); }
();http:///dangtuangongzuozongjie/ 党团工作总
结
();
}
private void button2_Click(object sender, EventArgs e) {
= "";
= "";
}
}
}
三. 会员管理模块
代码如下:
using System;
using ;
using ;
using ;
using ;
using ;
using ;
using ;
namespace WindowsApplication1
{
public partial class Form2 :
Form
{
protected SqlConnection conn;
protected SqlCommand cmd;
string connstring = @"Data Sou/article/ 述职报告rce=panlunzhao;Initial Catalog=;Integrated Security=True";
public Form2()
{
InitializeComponent();
}
private void Form2_Load(object sender, EventArgs e)
{
load1();
load();
}
protected void load1()
{
string sql = "select *from customer";
conn = new SqlConnection(connstring);