Wait For Document Validation Action And Resume - cannot be serialized error

Hello, I am having an issue that when using the “Wait For Document Validation Action And Resume” activity in my workflow I am getting a cannot serialize error. I have seen this issue come up a few times in different posts however I still cannot find a fix.
Main.xaml (46.0 KB)
I was wondering if anyone knew how to solve this issue? any help would be greatly appreciated.

I have upload my main.xaml file to this post and added the full error message below:

RemoteException wrapping
System.Runtime.Serialization.InvalidDataContractException: Type ‘System.Collections.IEnumerable’ 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)

Hi @gav_b,
If it’s possible please attach whole project as from main.xaml only there is no possibility to resolve all dependencies and it’s hard to know which exact version of which packages have you used. Ideally would be if you could describe a little what your process is doing and at which step (using debug) the error occurs.


Do you have an email i can send the whole project file too? and All the process is doing is extracting some information from a pdf and if the confidence is low creating an action in orchestrator. the error occurs on the “Wait For Document Validation Action And Resume” activity.


You can send the project using direct message to me.

Hi Pablito,

I have just sent you the message

1 Like

Hmmm to be honest I’m little bit lost in this. It’s hard to help as many things are combined together etc. I just see this:

It would be better and easier to figure out and navigate if you will divide your process per section/action and use some Invoke Workflow passing the arguments in and out. When I had similar problems many times I figured out what is wrong when I was trying to cleaning the process this way.