title: Can't use something like "me" or "this" keyword in wf4 xaml activity?
body: <p>We have implemented a class <code>ActivityException</code>, where the constructor accepts (amongst others) an argument of type <code>System.Activities.Activity</code>. This argument is used to create an error message that contains <code>Activity.DisplayName</code> and <code>Activity.Id</code>.</p>
  
  <p>This works very fine for WF4 activities written in C#. Here I can use something like:</p>
  
  <pre><code>throw new ActivityException(this, ...)
  </code></pre>
  
  <p>But now I am implementing a WF4 activity in xaml format (i.e. using workflow editor). If I throw an exception here, I have to use the <code>System.Activities.Statements.Throw</code> activity. I filled the <code>Exception</code> parameter of this activity as follows:</p>
  
  <pre><code>new ActivityException(Me, ...)
  </code></pre>
  
  <p>But the workflow editor says: "'Me' is valid only within an instance method".</p>
  
  <p>I also tried 'this' instead of 'Me', but this produces an error message, too.</p>
  
  <p>Does anybody have an idea how to solve this problem?</p>