locked
How to dynamically load a custom activity, which contains the receive activity RRS feed

  • Question

  • Good day. I'm from the user calls another user aktiviti aktiviti, which contains receive and stored locally in a file (xaml). Client - a console application. When you start ... when the process reaches the load xaml

    Stream

     

     

    stream = new MemoryStream(ASCIIEncoding.Default.GetBytes(input));

     

     

    Activity a = ActivityXamlServices.Load(stream) as Activity;

    WorkflowInvoker.Invoke(a);
    I load the Xaml, which contains receive activity. I'll show how to pass parameters to receive. Now I see this picture: as soon as execution reaches the load xaml and ... everything hangs until the collapse of all exception - timeout.Show you can download a xaml dynamically, if it contains aktiviti receive and how to add parameters to receive.And if you can'll show on another issue. I created a custom aktiviti. Compile and add it to the new user aktiviti. Save. If I try to download the latest aktiviti through dynamic loading xaml, it gave me an error: Cannot create unknown type '(clr-namespace: WorkflowConsoleApplication1) CodeActivity1' In this case both aktiviti lie in the same assembly. I can solve the problem of changing hands xaml, adding
    Was xmlns: ea = "clr-namespace: EMC.ActivityLibrary"
    So xmlns: ea = "clr-namespace: EMC.ActivityLibrary; assembly = ECM.ActivityLibrary" Is it possible to dynamically solve this problem, so no need to edit xaml hands?


    Tuesday, February 2, 2010 3:59 PM

Answers

  • This is a known issue with Dev10.  At this time the workaround, as you have already guessed, is to provide the assembly name of the activity when you're dynamically load the xaml.
    Thanks!
    Scott
    MS Developer Support
    Wednesday, February 3, 2010 1:45 AM

All replies

  • This is a known issue with Dev10.  At this time the workaround, as you have already guessed, is to provide the assembly name of the activity when you're dynamically load the xaml.
    Thanks!
    Scott
    MS Developer Support
    Wednesday, February 3, 2010 1:45 AM
  • Good day. Podskazhite, is it possible to dynamically load the Xaml, which represents a custom activity, which includes the receive activity. At the moment I see a picture: the process of load xaml and begins to perform ... As soon as reaches the receive activity, then everything freezes. Since waiting for a call from the client. And how can it be, if it all works dynamically. Tell me ... if I have the opportunity - dynamically load a custom activity, which contains the receive activity???
    Wednesday, February 3, 2010 10:31 AM
  • Hi buka82,

    I have same problem.

    did you resolve?,

    Friday, October 7, 2011 6:27 AM