摘要: 连接数据库, 请根据用用户的输入和数据库里的信息进行比较, 判断用户名和密码是否正确数据库设计:数据库名: MyDataBase1.mdf表名: T_Users表数据:程序代码[csharp] view plaincopyprint?usingSystem;usingSystem.Collections.Generic;usingSystem.Text;usingSystem.Data.SqlClient;namespace登录{classProgram{staticvoidMain(string[]args){//下面这段文字的作用已经在其它博文中解释! stringdataDir=AppD 阅读全文
posted @ 2012-07-26 14:54 keyen 阅读(28736) 评论(1) 推荐(4) 编辑
摘要: 读配置很简单,可以用ConfigurationManager.AppSettings[key] 来读出,可是写配置文件时,如果写成这样ConfigurationManager.AppSettings[key] = "111";总是提示只读,那么该怎么办呢?[c-sharp] view plaincopyprint?usingSystem;usingSystem.Collections.Generic;usingSystem.Text;usingSystem.Configuration;namespaceBQKJ.Common{///<summary> ///对e 阅读全文
posted @ 2012-07-26 13:27 keyen 阅读(2386) 评论(0) 推荐(0) 编辑