Durable Task Framework allows users to write long running persistent workflows in C# using the async/await capabilities.
Apache License 2.0
1.51k
stars
290
forks
source link
Unable to find a constructor to use for type System.DirectoryServices.SearchResult. A class should either have a default constructor, one constructor with arguments or a constructor marked with the JsonConstructor attribute. #1002
I have a TaskActivity that returns an object of type MySearchResult, that in turn has a property of type List<System.DirectoryServices.SearchResult>. The problem is that SearchResult doesn't have a public parameterless constructor, and so Newtonsoft fails to serialize it.
I have a TaskActivity that returns an object of type
MySearchResult
, that in turn has a property of typeList<System.DirectoryServices.SearchResult>
. The problem is thatSearchResult
doesn't have a public parameterless constructor, and so Newtonsoft fails to serialize it.The following code throws a Newtonsoft exception:
How can I work around this issue?