Question

How to create process flow that checks if documents have been uploaded

  • 21 March 2024
  • 3 replies
  • 80 views

Badge

So I have been trying to create this process flow - with the help of some amazing developers at Thinkwise - that checks if there are documents uploaded and based on this decision, show a warning message that the user forgot to upload the documents (don’t show any warning if there are already documents, instead run the main task immediately).

So my process flow looks like this (see images through this link https://imgur.com/a/QqBVNpQ). I created a ‘fake’ process action Ready_for_billing_outbound_order (the first one) I give it two output task parameters: outbound_order_id and documents_complete.

I linked this to a decision with no input or output, just a functionality (see third image). Based on the if statement, either the warning is shown or the task runs.

The problem starts when I try to run a creation, I get error(s) and one of them is: No declarable variable @execute_tab_task_outbound_order_check_show_msg_no_proof_of_delivery_invoice

How does this process flow work and what do the error(s) mean?


3 replies

Userlevel 7
Badge +23

Hi Alieev,

The error message indicates you are using an undefined variable. To fix the code shown in the imgur picture, replace the exec stuff.

Code should look like this I think:

if @document_complete_invoice = 1 -- Has documents
begin
set @decide_msg_execute_task_has_documents = 1 -- Go to Execute task step

set @decide_msg_execute_task_has_no_documents = 0 -- Do not show the message
end
else if @document_complete_invoice = 0 -- Has no documents
begin
set @decide_msg_execute_task_has_documents = 0 -- Do not go to Execute task step

set @decide_msg_execute_task_has_no_documents = 1 -- Show the message
end

This code sets the variables that determine which process step is followed. In the header of this logic you can see the variables and behind them the variables are explained. More info here: https://docs.thinkwisesoftware.com/docs/sf/process_flows#business-logic-in-a-process-flow

Hope this helps!

Badge

Hi Mark,

Thanks for your response. That fixed some of the issues, still got some error(s) left. Now a new challenge arises.

Userlevel 5
Badge +8

Hi @Alieev,

Do you still need support for the remaining/new challenges? 

Reply