By Neeraj Kumar on Friday, 06 December 2019
Posted in C# Development
Likes 0
Views 1K
Votes 0
My Macro reads devices inside cabinet and keep in List so later it sort based on some criteria. But some point its crash due to outofmemory exception while calling TryFindById function of attributes. How this can be handle? I am attaching the details of exception also.

Stack trace:
Server stack trace:
at System.Runtime.Remoting.Messaging.SmuggledMethodCallMessage.FixupForNewAppDomain()
at System.Runtime.Remoting.Channels.CrossAppDomainSink.DoDispatch(Byte[] reqStmBuff, SmuggledMethodCallMessage smuggledMcm, SmuggledMethodReturnMessage& smuggledMrm)
at System.Runtime.Remoting.Channels.CrossAppDomainSink.DoTransitionDispatchCallback(Object[] args)

Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Aucotec.EngineeringBase.Client.RuntimeContract.IAttributeCollection.TryFindById(AttributeId attributeId, IAttributeItem& attributeItem)
at Aucotec.EngineeringBase.Client.RuntimeAddInAdapter.AttributeCollectionAddInAdapterContractToView.TryFindById(AttributeId attributeId, AttributeItem& attributeItem)
at ABB.ATBPA.EB800xAIntegration.Utils.ObjectItemExtensions.GetAttrStringValue(ObjectItem obj, AttributeId id)
at ABB.Engg.CabinetCalculation.BOM.Cabinet.<.ctor>b__0(ObjectItem x)
at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
at ABB.Engg.CabinetCalculation.BOM.Cabinet..ctor(ObjectItem cabObject)
at ABB.Engg.CabinetCalculation.BOM.MainWindowViewModel..ctor(Project project, ObjectItem selectedObject)
at ABB.Engg.CabinetCalculation.BOM.MyPlugIn.Run(Application myApplication)
at Aucotec.EngineeringBase.Client.RuntimeAddInAdapter.PlugInWizardAddInAdapterViewToContract.Run_Internal(Object app)
View Full Post