This project is read-only.

XamlInjector "decompiles" the activity

Feb 22, 2013 at 12:23 AM

I want to test the workflow and want to replace activiteis with XamlInjector.
It looks like that XamlInjector doesn't support expressions.
I've created simple activty that just calls WriteLine and Text is expression string.Format(...).
If I compile it and run as in example below I don't see problems.

How can I make it work with XamlInjector? Is there another solution to this problem?

That works:

Activity toRun = new MyActivity();
var testHost = new WorkflowInvokerTest(toRun);
var result = testHost.TestActivity();

That doesn't:

var xamlInjector = new XamlInjector("MyActivity.xaml");
var testHost = new WorkflowInvokerTest(xamlInjector.GetActivity());
var result = testHost.TestActivity();

Best regards,
Feb 23, 2013 at 1:00 AM
Edited Feb 23, 2013 at 1:00 AM
It looks like if you use VB expressions this is not an issue. Apparently XamlInjector doesn't support C# expressions.