Error when creating documents in PW V8i


 Product(s):ProjectWise Caching Server
 Version(s):08.11.XX.XX
 Original Author:Bentley Technical Support Group

Problem

Error when creating documents in ProjectWise V8i
No new documents can be created in PW 8.11.5.16 either in PWE or through Web Parts. The error in PWC is: "Last Error [58117]. Field value must be unique." The error in Web Parts is:

"Server Error in '/' Application.
--------------------------------------------------------------------------------

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.]
   Bentley.EC.Presentation.View.ValueListsModifier.CreateQueryBackedValueListAttribute(RepositoryConnection connection, ECQuery valueListQuery, String valuePropertyName, String displayStringPropertyName, Type type) +833
   Bentley.EC.Presentation.View.ValueListsModifier.SetValueList(RepositoryConnection connection, FieldDisplayInfo fieldInfo, ECQuery instancesQuery) +222
   Bentley.ECOM.ProjectWiseProvider.DocumentViewRetriever.AddDocumentPropertiesViewAttribGuiFields(ECQuery documentQuery, RepositoryConnection connection, List`1 fieldDisplayInfos, IECSchema staticSchema, IECSchema dynamicSchema, Boolean readOnly, Boolean finalStatus, ECQuery environmentIdQuery, String contextNodeId) +2902
   Bentley.ECOM.ProjectWiseProvider.DocumentViewRetriever.AddNewDocumentPropertiesViewAttribGuiFields(ECQuery documentQuery, RepositoryConnection connection, ECTypedKey parentKey, List`1 fieldDisplayInfos, IECSchema staticSchema, IECSchema dynamicSchema, Boolean readOnly) +234
   Bentley.ECOM.ProjectWiseProvider.DocumentViewRetriever.GetNewDocumentView(RepositoryConnection connection, NavNode navNode, IExtendedParameters contextMap) +2665
   Bentley.ECOM.ProjectWiseProvider.DocumentViewRetriever.GetNewInstanceView(ECView ecView, NavNode navNode) +82
   Bentley.ECOM.ProjectWiseProvider.BaseViewRetriever.GetView(ECView ecView, NavNode navNode, String[] classIdsIn, String[] classIdsEx) +252
   Bentley.ECOM.ProjectWiseProvider.DocumentViewRetriever.GetView(ECView ecView, NavNode navNode, String[] classIdsIn, String[] classIdsEx) +139
   Bentley.ECOM.ProjectWiseProvider.BaseViewRetriever.GetView(ECView ecView, NavNode navNode) +245
   Bentley.ECOM.ProjectWiseProvider.ProjectWiseViewProvider.GetView(RepositoryConnection connection, ECView ecView, NavNode navNode, String[] requiredFields, IExtendedParameters contextMap) +156
   Bentley.EC.Presentation.View.ViewServiceInProcess.GetView(RepositoryConnection connection, NavNode navNode, String[] requiredFields, IExtendedParameters extendedParameters) +161
   Bentley.EC.Web.UI.WebControls.WebParts.Content.LoadContentGroups() +715
   Bentley.EC.Web.UI.WebControls.WebParts.Content.EnsureContentGroups() +15
   Bentley.EC.Web.UI.WebControls.WebParts.Content.CreateChildControls() +14
   System.Web.UI.Control.EnsureChildControls() +87
   System.Web.UI.Control.PreRenderRecursiveInternal() +50
   System.Web.UI.WebControls.WebParts.WebPart.PreRenderRecursiveInternal() +62
   System.Web.UI.Control.PreRenderRecursiveInternal() +170
   System.Web.UI.Control.PreRenderRecursiveInternal() +170
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2041

--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433 "

Solution

Check the environment attributes of the folder that documents cannot be created in. The issue can be caused by environment attributes Value lists of wrong type. For instance, there may be an environment attribute Attr1 of type Date and if it has a fixed Value list consisting of text strings Obsolete|Valid - that will cause the error mentioned above. Solution is to make sure that all of the Value lists for environment attributes are adequate. The value lists are stored in the table DMS_EVAL of the database.

See Also

Product TechNotes and FAQs

External Links

Bentley Technical Support KnowledgeBase

Bentley LEARN Server

Comments or Corrections?

Bentley's Technical Support Group requests that you please confine any comments you have on this Wiki entry to this "Comments or Corrections?" section. THANK YOU!