1 Reply Latest reply on Apr 10, 2006 7:36 AM by Koen Aers

    Error with the jbpm context

    jmix2006 Newbie


      this is the problem:

      int the action Taskaction i open a jbpmcurrentcontext and i attribute to him an actorid.

      in the page : viewtask.jsp , when I want to get the actorid the response was null .

      My code :
      1. a part of web.xml


      2. the taskaction.java:
      Taskform taskform = (Taskform) form;
      String username = taskform.getUsername();
      JbpmContext jbpmcontext=JbpmContext.getCurrentJbpmContext();

      3. a part of viewtask.jsp
      <TABLE border="1" width="200px">
       Tasklist tl=new Tasklist();
       String actor=tl.acteur();
       Iterator it = tl.tache(actor).iterator();
       while(it.hasNext()) {
      <% } %>

      4. Tasklist.java:

      public class Tasklist{
      public String acteur()
      JbpmContext jbpmcontext=JbpmContext.getCurrentJbpmContext();
      return (jbpmcontext.getActorId()) ;
      public List tache(String s){
      JbpmContext jbpmcontext=JbpmContext.getCurrentJbpmContext();
      TaskMgmtSession taskmgmtsession =jbpmcontext.getTaskMgmtSession();
      List l = taskmgmtsession.findTaskInstances(s) ;
       return l;

      Why Jbpmcontext retu rn an "null" actorid ??

      Thanks for your help.