using System; using System.Collections.Generic; using System.Text; using System.Configuration; using System.Data; using System.Data.SqlClient; using CG67.FicheCollege.Domaine; namespace CG67.FicheCollege.Entrepot { public class EntrepotBase { protected string ChaineDeConnexion; protected string ChaineDeConnexionCollege; protected string ChaineDeConnexionSubvention; // protected string ChaineDeConnexionAccess; public EntrepotBase() { this.ChaineDeConnexion = ConfigurationManager.AppSettings["ConnexionStringSic"]; if (string.IsNullOrEmpty(this.ChaineDeConnexion)) { throw new Exception("Chaine de connexion Sql Server non renseignée"); } this.ChaineDeConnexionCollege = ConfigurationManager.AppSettings["ConnexionStringOracleCollege"]; if (string.IsNullOrEmpty(this.ChaineDeConnexionCollege)) { throw new Exception("Chaine de connexion Oracle non renseignée"); } this.ChaineDeConnexionSubvention = ConfigurationManager.AppSettings["ConnexionStringOracleSubvention"]; if (string.IsNullOrEmpty(this.ChaineDeConnexionSubvention)) { throw new Exception("Chaine de connexion Oracle non renseignée"); } //this.ChaineDeConnexionAccess = ConfigurationManager.AppSettings["ConnexionStringAccess"]; //if (string.IsNullOrEmpty(this.ChaineDeConnexionAccess)) //{ // throw new Exception("Chaine de connexion Access non renseignée"); //} } } }