ResumeAfterDelay Error

Hi everyone!

I am having an issue using the ResumeAfterDelay Activity.
I get the following error message:


Message: Type 'System.__ComObject' cannot be serialized. Consider marking it with the DataContractAttribute attribute, and marking all of its members you want serialized with the DataMemberAttribute attribute.  If the type is a collection, consider marking it with the CollectionDataContractAttribute.  See the Microsoft .NET Framework documentation for other supported types.

Exception Type: System.Runtime.Serialization.InvalidDataContractException

RemoteException wrapping System.Runtime.Serialization.InvalidDataContractException: Type 'System.__ComObject' cannot be serialized. Consider marking it with the DataContractAttribute attribute, and marking all of its members you want serialized with the DataMemberAttribute attribute.  If the type is a collection, consider marking it with the CollectionDataContractAttribute.  See the Microsoft .NET Framework documentation for other supported types. 
   at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
   at System.Activities.WorkflowApplication.IdleEventHandler.OnStage2Complete(IAsyncResult lastResult, WorkflowApplication instance, Boolean isStillSync)
   at System.Activities.WorkflowApplication.EventFrame(IAsyncResult result)

I do not get this error message if i run the activity by itself, only when it is part of the rest of the workflow. However, the error happens in the middle of the activity (I checked with a console log before and after the ResumeAfterDelay and it never gets to after the ResumeAfterDelay). So I’m not sure what would be different and causing the issue.

I have never encountered this issue before so I’m not sure how to go about debugging it.

Thanks in advance!

Can you post the screenshot of the activity and the activity which is before the delay activity?

1 Like

Basically, the process around the activity does the following: Gets the current Date Time. ResumesAfterDelay of current Date Time + adds dbl variable of 0.25 hours. so it resumes in 15 minutes. It fails shortly after the activity starts. It does not get this far, but After the delay, it checks if an element exists. If it doesn’t, it loops back to resume after another 15 minute delay. If the element does exist, it continues along the process.

This is the snippet around the Activity
process%20overview

This is the properties tab of the ResumeAfterDelay.
ResumeAfterDelayProperties

This is inside the Check Report Status Sequence after the ResumeAfterDelay
Check%20Report%20Status

did you find a fix for this?

Did anyone get an answer for this…?