You could also use a ServiceCall component, completely avoiding having to navigate in the flow of the diagram. Simply bind a Service Call component to your service, and call it from the change event like:
{MyServiceCall}.execute(reqObj);
Simply build your reqObj before, in this case reqObj is a complex object. The only downside with serviceCall is that you only can have one input variable, but you can just create reqObj business objects in your application.
By "hiding" the service in a ServiceCall instead of NavigationEvent, you avoid your cshs diagrams being cluttered.
------------------------------
Johan Andersson
Johan.andersson@apendo.se------------------------------
Original Message:
Sent: Fri April 19, 2024 03:48 AM
From: El Mehdi ES-SAFI
Subject: Calling service flows from onChange Event
Oh, thank you Dave for your response. Yes, that's exactly it. Instead of using a button and hiding it, I should use the Navigation Event Thank you so much for your help
------------------------------
El Mehdi ES-SAFI
Original Message:
Sent: Thu April 18, 2024 09:51 AM
From: DAVE PERMAN
Subject: Calling service flows from onChange Event
Also check out the Navigation Event UI View which was designed specifically for that purpose.
Like button UI Views, they also show up when selecting the view that triggers the outbound boundary events from the page.
------------------------------
DAVE PERMAN
Original Message:
Sent: Wed April 17, 2024 02:57 AM
From: El Mehdi ES-SAFI
Subject: Calling service flows from onChange Event
Hi Ahmed ,
Thank you for taking the time to respond to me. I found a solution that meets my needs: I added a hidden button and added this line of code( ${Button1}.click(); ) to the onchange
event of variable1. It's working like magic!

------------------------------
El Mehdi ES-SAFI
Original Message:
Sent: Wed April 17, 2024 02:41 AM
From: Ahmed Ibrahim
Subject: Calling service flows from onChange Event
Hi El Mehdi, You can create a listener in view for onchange of variable1 then call the service as explained in https://www.ibm.com/docs/en/bpm/8.5.0?topic=views-calling-ajax-services-from-coach
------------------------------
Ahmed Ibrahim
Original Message:
Sent: Tue April 16, 2024 01:04 PM
From: El Mehdi ES-SAFI
Subject: Calling service flows from onChange Event
Hello everyone, I hope you are all doing well.
Please, I'm looking for help. I want to call a service flow during the onchange
event (when the value of a field variable1 changes, I call the service flow (ServiceECM) ) on BAW. Is there a way to do this? If anyone has done it before, can you please share an example with me?
Thank you.


------------------------------
El Mehdi ES-SAFI
------------------------------