Question : Operation is not valid due to the current state of the object.

Hello,

I have stack trace turned on in the web config file and seeing some more details about the error I am experiencing. I have a WSS 3.0 site on Windows 2003 Server. Any ideas of what could be wrong?

Here is the error:

Operation is not valid due to the current state of the object.
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: System.InvalidOperationException: Operation is not valid due to the current state of the object.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.  

Stack Trace:


[InvalidOperationException: Operation is not valid due to the current state of the object.]
   Microsoft.SharePoint.Library.SPRequestInternalClass.OpenWebInternal(String bstrUrl, Guid& pguidID, String& pbstrRequestAccessEmail, UInt32& pwebVersion, String& pbstrServerRelativeUrl, UInt32& pnLanguage, UInt32& pnLocale, String& pbstrDefaultTheme, String& pbstrDefaultThemeCSSUrl, String& pbstrAlternateCSSUrl, String& pbstrCustomizedCssFileList, String& pbstrCustomJSUrl, String& pbstrAlternateHeaderUrl, String& pbstrMasterUrl, String& pbstrCustomMasterUrl, String& pbstrSiteLogoUrl, String& pbstrSiteLogoDescription, Object& pvarUser, Boolean& pvarIsAuditor, Int32& plSiteFlags) +0
   Microsoft.SharePoint.Library.SPRequest.OpenWebInternal(String bstrUrl, Guid& pguidID, String& pbstrRequestAccessEmail, UInt32& pwebVersion, String& pbstrServerRelativeUrl, UInt32& pnLanguage, UInt32& pnLocale, String& pbstrDefaultTheme, String& pbstrDefaultThemeCSSUrl, String& pbstrAlternateCSSUrl, String& pbstrCustomizedCssFileList, String& pbstrCustomJSUrl, String& pbstrAlternateHeaderUrl, String& pbstrMasterUrl, String& pbstrCustomMasterUrl, String& pbstrSiteLogoUrl, String& pbstrSiteLogoDescription, Object& pvarUser, Boolean& pvarIsAuditor, Int32& plSiteFlags) +168
   Microsoft.SharePoint.SPWeb.InitWebPublic() +522
   Microsoft.SharePoint.SPWeb.get_Locale() +122
   Microsoft.SharePoint.WebPartPages.Utility.SetThreadCulture(SPWeb spWeb, Boolean force) +70
   Microsoft.SharePoint.WebPartPages.Utility.SetThreadCulture(SPWeb spWeb) +46
   Microsoft.SharePoint.CoreResource.GetString(ResourceGroup rg, String name, Object[] values) +737
   Microsoft.SharePoint.SPResource.GetString(String name, Object[] values) +39
   Microsoft.SharePoint.Administration.SPContentDatabase.ValidateDatabaseSchemaCompatibility() +492
   Microsoft.SharePoint.SPSite.PreinitializeServer(SPRequest request) +59
   Microsoft.SharePoint.SPWeb.InitializeSPRequest() +290
   Microsoft.SharePoint.SPWeb.EnsureSPRequest() +58
   Microsoft.SharePoint.SPWeb.get_Request() +54
   Microsoft.SharePoint.WebControls.SPControl.SPWebEnsureSPControl(HttpContext context) +401
   Microsoft.SharePoint.WebControls.SPControl.GetContextWeb(HttpContext context) +31
   Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.PostResolveRequestCacheHandler(Object oSender, EventArgs ea) +385
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +68
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75

 

Answer : Operation is not valid due to the current state of the object.

Random Solutions  
 
programming4us programming4us