User-1885255629 posted
System.InvalidOperationException: Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections
were in use and max pool size was reached
---Here is the code-----
{
string connectionstring = ConfigurationManager.ConnectionStrings["CWGCartConnectionString"].ToString();
SqlDataReader reader1 = null;
SqlParameter[] parameterArray1 = new SqlParameter[1];
parameterArray1[0] = new SqlParameter("@custID", SqlDbType.Int);
parameterArray1[0].Value = custID;
try
{
reader1 = SqlHelper.ExecuteReader(connectionstring, CommandType.StoredProcedure, "x_stored_procedure", parameterArray1);
}
catch (SqlException exception1)
{
string text1 = "Error Executing x_stored_procedure: \r\n";
foreach (SqlParameter parameter1 in parameterArray1)
{
object obj1 = text1;
text1 = string.Concat(new object[] { obj1, parameter1.ParameterName, "=", parameter1.Value, "\r\n" });
}
throw new Exception(text1, exception1);
}
return reader1;
}