我想知道如何在工作流书签中传递多个输入参数。我有这个代码
public sealed class CodeActivity1 : NativeActivity<String>
{
[RequiredArgument]
public InArgument<string> BookmarkName { get; set; }
protected override void Execute(NativeActivityContext context)
{
context.CreateBookmark(BookmarkName.Get(context),
new BookmarkCallback(OnResumeBookmark));
}
// NativeActivity derived activities that do asynchronous operations by calling
// one of the CreateBookmark overloads defined on System.Activities.NativeActivityContext
protected override bool CanInduceIdle
{
get { return true; }
}
public void OnResumeBookmark(NativeActivityContext context, Bookmark bookmark, object obj)
{
Result.Set(context, (string)obj);
}
}
当我像 app.ResumeBookmark("Test", "inputTest"); 一样恢复它时。但是,如果我有例如 2 个输出参数,例如
public InArgument<string> BookmarkName { get; set; }
public OutArgument<string> Test1 {get; set;}
public OutArgument<string> Test2 {get; set;}
如何使用 app.ResumeBookmark() 调用此书签?并从外部设置 2 个 OutArguments?像 app.ResumeBookmark("Test","Inputtest1","Inputtest2")?谢谢你的时间