You are viewing limited content. For full access, please sign in.

Question

Question

Managed Mode

asked on April 14, 2014

 I am trying to run my script in managed mode. The script is being done in Workflow. I would like to know if anyone had any insight on this with running in this specific mode or if it is even possible to run a script in Workflow through this mode. 

 protected override void Execute()
        {
            // Write your code here. The BoundEntryInfo property will access the entry, RASession will get the Repository Access session
            Start();
        }

        public void Start(){
            thread = new Thread(new ThreadStart(beginProgram));
            thread.SetApartmentState(ApartmentState.STA);
            thread.Start();
        }

 

0 0

Answer

SELECTED ANSWER
replied on April 22, 2014

Creating new threads in a workflow script is not a supported action. Neither is starting external processes but you can do it through the System.Diagnostics.Process class.

0 0

Replies

replied on April 14, 2014

What exactly are you trying to accomplish?

0 0
replied on April 14, 2014

I currently have an external process to generate tiffs from office documents without the use of snapshot. I am currently trying to recreate this within the Workflow script editor so that it can be automated by Workflow. My current script works fine if I run the script itself though when I try to automate it through Workflow it throws an exception. I am trying to work around this by having the script ran in managed mode.

0 0
replied on April 14, 2014

What exception did you get?

0 0
replied on April 15, 2014
      'The invocation of the constructor on type 'System.Windows.Documents.DocumentReference' that matches the specified binding constraints threw an exception.' Line number '2' and line position '21'.
0 0
replied on April 22, 2014

Is there any word about this?

0 0
SELECTED ANSWER
replied on April 22, 2014

Creating new threads in a workflow script is not a supported action. Neither is starting external processes but you can do it through the System.Diagnostics.Process class.

0 0
replied on April 23, 2014

Hi Cristobal,

 

It looks like you have a number of good answers to your question. If one provided the answer you needed, please click the “This answered my question" button.

 

 

If you still need assistance with this matter, just update this thread. Thanks!

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.