Server Error in '/' Application.

There is already an open DataReader associated with this Connection which must be closed first.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: MySql.Data.MySqlClient.MySqlException: There is already an open DataReader associated with this Connection which must be closed first.

Source Error:


Line 55: 	    
Line 56:     Public Function validateSuburbURL() As Boolean
Line 57:         If Nexus.sqlGetInt("Select COUNT(id) from towns Where Suburb = '" & Nexus.sqlValid(strSuburb) & "' and Council='" & Nexus.sqlValid(strCouncil) & "';") = 0 Then
Line 58:             Return False
Line 59:         End If

Source File: C:\websites\architects.net.au\www\architects.aspx    Line: 57

Stack Trace:


[MySqlException (0x80004005): There is already an open DataReader associated with this Connection which must be closed first.]
   MySql.Data.MySqlClient.MySqlCommand.CheckState() +444
   MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior) +166
   MySql.Data.MySqlClient.MySqlCommand.ExecuteScalar() +38
   Nexus.sqlGetInt(String strSQL) +48
   ASP.architects_aspx.validateSuburbURL() in C:\websites\architects.net.au\www\architects.aspx:57
   ASP.architects_aspx.Page_Load(Object sender, EventArgs e) in C:\websites\architects.net.au\www\architects.aspx:36
   System.Web.UI.Control.OnLoad(EventArgs e) +132
   System.Web.UI.Control.LoadRecursive() +66
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2428


Version Information: Microsoft .NET Framework Version:2.0.50727.8974; ASP.NET Version:2.0.50727.8974