[jboss-user] [JBoss jBPM] - Default value for a task variable?

khamburg do-not-reply at jboss.com
Tue Apr 17 14:46:26 EDT 2007

I want to find a simple way to initialize a task variable. I tried to do it with a script:

  | <task-node name="tNode">
  | 	<task name="tName">
  | 	<event type="task-create">
  | 		<script>
  | 			contextInstance.variables.a = "yes";
  | 		</script>
  | 	</event>
  | 	<controller>
  | 		<variable name="a" access="read,write">
  | 		</variable>
  | 	</controller>
  | 	</task>
  | </task-node>

but I get an error:

  | SEVERE: Error taking transition: Sourced file: inline evaluation of: ``contextInstance.variables.a= "yes";'' : Field access: bsh.ReflectError: No such field: a

I tried all the supported event types: {task-create|task-start|task-assign|task-end} and got the same result. 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4038102#4038102

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4038102

More information about the jboss-user mailing list