private bool CheckConnection() { var connectionString = ServerWrapper.GetConnectionString(); try { SqlConnection testConnection = new SqlConnection(connectionString); testConnection.Open(); testConnection.Close(); return(true); } catch (Exception) { return(false); } }
public ApplicationDbContext() : base(ServerWrapper.GetConnectionString()) { }