EBDN - Community - Question & Answers

  Wednesday, 28 April 2021
  2 Replies
  693 Visits
0
Votes
Undo
Setting an Attribut on a Project with the same values works well, but
trying to set an Attribute on a projects documents folder with this code


ObjectItem pDoc = myProject.DrawingsFolder;
pDoc.Attributes.SetAttributeValue(attid, value);
pDoc.Store();


the Store-operation fails with the Exception

Systemfehler bei der VBA-Integration!

Server stack trace:
bei Aucotec.EngineeringBase.Client.RuntimeHostAdapter.DrawingsHostAdapterViewToContract.Store()
bei System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Object[]& outArgs)
bei System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)

Exception rethrown at [0]:
bei System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
bei System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
bei Aucotec.EngineeringBase.Client.RuntimeContract.IObjectItem.Store()
bei Aucotec.EngineeringBase.Client.RuntimeAddInAdapter.DrawingsAddInAdapterContractToView.Store()
bei EBEDM.EBIPC.SetPartAttribute(Object pModelDoc, String parameter, String value)
bei EBEDM.EBIPC.SetAttributesFromExportfile(Object pModelDoc, StreamReader fp, String saveas)
bei EBEDM.EBIPC.SaveMgmtSave(List`1 documents, StreamReader fp)

The property is seen on the pDoc.Attributes collection so SetAttributeValue works as expected. The store operation fails. What am I missing ?