资源描述:
《上机实习报告总结结尾.doc》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、上机实习报告总结结尾一.首页
代码如下;
usingSystem;
using;
using;
using;
using;
using;
using;
namespaceWindowsApplication1
{
publicpartialclassForm5:Form{
publicForm5()
{
InitializeComponent();
}
privatevoidbutton1_Click(objectsende溶r,{
logofrom徐=newlogo();慈
();EventArg拒se)
}
p
2、riva潍tevoidbutto砧n2_Click(ob棚jectsender,碱EventArgse)妥{
Form2fro环m=newForm2(衷);
();
}
pri员vatevoidbut群ton3_Click(晌objectsende兑r,EventArgs农e)http:///s握hijuan/试卷{
垦 Form3from=郧newForm3();杏
();
}
priva红tevoidbutto翼n4_Click(ob雍jectsender,沾EventArgse)菲{
Form4fro扛m=ne
3、wForm4(锄);
();
}
}
}
二.登握录模块
代码如下:
usi赴ngSystem;
us莫ing;
using;
u矾sing;
using
;溪
using;
using唆;
using;
na扭mespaceWind呛owsApplicat绎ion1
{
publ赤icpartialcl腔asslogo:For怖m
{
publiclog扎o()
{
Initi浚alizeCompon栖ent();
}
pr扇ivatevoidFo混rm1_Load(ob墟jectsender,迫EventArgse
4、)琴
{
}
private结voidbutton1盟_Click(obje聂ctsender,Ev枝entArgse){
造 stringconn渣string="Dat奥aSource=pan矣lunzhao;Ini谱tialCatalog返=;Integrate隐dSecurity=T锋rue";
SqlC敦onnectionco燕nn=newSqlCo拯nnection(co锐nnstring);(掌);
stringu坷sername=();矫stringpassw印ord=();SqlC六ommandcomm
5、=佰();
="sele励ct*frommana蛛gewhereuser暴name='"+use猩rname+"'and伞password='"婴+password+"扳'";
SqlDat蔡aReadersqld舔a=();
if(())炕
{
ifhttp:/慈//gongzuoba仓ogao/工作报告(s擂qlda.ToStri搭ng().Trim()吉==password)妖{
//("恭喜您登丰陆成功!","登陆成功费!",,);
//For乙m2f=newForm匝2();
//();
瞬Form3fr
6、om=n引ewForm3();
(粉);
}
else{(辉"密码错误,请重新输入飘!","错误
",,);填}
}
else{("柔此用户不存在,请您注册丈!","注册",,);涎}
();http:付///dangtuan就gongzuozong考jie/党团工作总结
(坞);
}
privat樱evoidbutton警2_Click(obj憎ectsender,E睬ventArgse){突
="";
="";
}
}
}忽
三.会员管理模块
代码如香下:
usingSyst冷em;
using;
us榨ing;
7、using;
u牲sing;
using;侩
using;
using栓;
namespac眼eWindowsApp儿lication1
{
撮 publicpart种ialclassFor狡m2:
Form
{
p跃rotectedSql氏Connectionc喳onn;
prote绪ctedSqlComm暂andcmd;
st新ringconnstr统ing="DataSo钳u/article/述叔职报告rce=panl卸unzhao;Init沁ialCatalog=梗;Integrated媚Security=T
8、r誊ue";
publicF峰orm2()
{
In带itializeCom去ponent();
}
誉 privatevoi要dForm2_Load冤(objectsend舜er,EventArg铬se)
{
l