连接数据库

xiaoxiao2021-02-27  210

public clsDataBaseLayer(string strConnect, string dataType)         {             if (dataType.ToUpper() == "ORACLE")             {                 this.ConnectionString = Get_ConnectionString(strConnect);             }             else             {                 this.ConnectionString = strConnect;             }             this.DbType = dataType;         }         public clsDataBaseLayer()         {             try             {                 this.dbType = ConfigurationSettings.AppSettings["DataType"];                 if (this.dbType.ToUpper() == "ORACLE")                 {                     this.connectionString = Get_ConnectionString(ConfigurationSettings.AppSettings["ConnectionString"]);                 }                 else                 {                     this.connectionString = ConfigurationSettings.AppSettings["ConnectionString"];                 }             }             catch (System.Exception ex)             {                 throw new Exception(ex.Message);             }                    }
转载请注明原文地址: https://www.6miu.com/read-10422.html

最新回复(0)