下面代码是本人封装的一个sqlHelper类。主要功能是对数据库的CURD。以及存储过程、事物、分页的实现。(首先要引入命名空间using System.Configuration;)

public class SqlHelper
{

#region 连接字符串
/// <summary>
/// 连接数据库的字符串
/// </summary>
private static string conStr = ConfigurationManager.ConnectionStrings["sqlconStr"].ConnectionString; 
#endregion
连接字符串

相关文章:

猜你喜欢
  • 2021-10-05
  • 2021-07-13
  • 2022-01-24
  • 2021-08-06
相关资源
相似解决方案