Skip to main content
Nov 21, 2023 1:08 PM UTC
Question

Workflow Creation Error

Hi Community,

 

I created a new flow by clicking new template from the templates page. But the flow gets stuck at the first step and gives an error that it should not give, what could be the reason for this?  Even though I defined all the parameters correctly, nothing changed.

Code:

wt.doc.WTDocument doc = (wt.doc.WTDocument) primaryBusinessObject;

 docNumber=doc.getNumber();
 docName=doc.getName();

 Error:

wt.workflow.engine.FailedExpressionException: wt.util.WTException: java.lang.NullPointerException
Nested exception is: java.lang.NullPointerException
Nested exception is: wt.util.WTException: java.lang.NullPointerException
Nested exception is: java.lang.NullPointerException

 

5 replies

Nov 21, 2023 1:33 PM UTC

Hi @smcvr 

You should be sure that the primaryBusinessObject is not null and also is the correct type.

 

PetrH

smcvrAuthor
Nov 21, 2023 1:37 PM UTC

Hi @HelesicPetr 

 

Yes, I am sure. When I try it with another previously created workflow, it does not give these errors. I think I'm getting this error because I created this with a new template.

Nov 21, 2023 1:48 PM UTC

Hi @smcvr 

In your code something is null(empty, without value), and you need to find what it is. 

PetrH