c# error as The ConnectionString property has not been initialized : why i'm getting connection state has not been intialized when i'm Using `one methode in other` 
    
        DbContext db = new DbContext();
    public Employee FindEmpById(int key)
        {
            SqlConnection conn = db.DbConnection;
            try
            {
                var employee = new Employee();
                if (conn.State != System.Data.ConnectionState.Open)
                {
                    conn.Open();
                }
                SqlCommand cmd = new SqlCommand("Sp_GetEmployeeById", conn);
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.Parameters.AddWithValue("@EmpId", key);
                SqlDataReader rdr = cmd.ExecuteReader();
                if (rdr.HasRows == true)
                {
                    while (rdr.Read())
                    {
                        employee.Emp_Id = Convert.ToInt32(rdr["Emp_Id"]);
                        employee.EmpName = rdr["EmpName"].ToString();
                        employee.Email = rdr["Email"].ToString();
                        employee.Psw = rdr["Psw"].ToString();
                    }
                }
                return employee;
            }
            catch (Exception)
            {
                throw;
            }
            finally{
                if (conn != null)
                {
                    if (conn.State == ConnectionState.Open)
                        conn.Close();
                        conn.Dispose();

This `FindEmpById` i call in `DeleteEmpById` function 

  

    public void DeleteEmpById(int Key)
            {
                SqlConnection Con = db.DbConnection;
               
                var x = FindEmpById(Key);
                if (x != null)
                {
                    if (Con.State != ConnectionState.Open)
                    {
                        Con.Open();
                    }
                    SqlCommand cmd = new SqlCommand("sp_DeleteById", Con);
                    cmd.CommandType = CommandType.StoredProcedure;
                    cmd.Parameters.AddWithValue("@EmpId", Key);
                    cmd.ExecuteNonQuery();
       
