<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Answers to: Trigger activity - no task</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task</link><description>&lt;p&gt;Hello All,&lt;/p&gt;
&lt;p&gt;I have a HTML Dialog. In the Logic I use the Trigger activity to call a Business Process.
It works, but it creates a task. &lt;/p&gt;
&lt;p&gt;Is there a way to be invoked immediately and not create and assign a task ?
My process is pure server-side logic.&lt;/p&gt;
&lt;p&gt;Best Regards,
Yordan Yunchov&lt;/p&gt;</description><atom:link href="https://answers.axonivy.com/questions/1905/trigger-activity-no-task" rel="self"></atom:link><language>en</language><lastBuildDate>Wed, 01 Mar 2017 09:07:47 -0500</lastBuildDate><item><title>Comment by Reguel Wermelinger on lttung's answer</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#2473</link><description>&lt;p&gt;In classical workflows you need a traceable history and therefore always need to know the creator task. 
But I guess you should be able to create a completely detached task/case if you create it via a REST or SOAP webservice.
For a REST example see the &lt;code&gt;ConnectivityDemos&lt;/code&gt; -&amp;gt; &lt;code&gt;com.axonivy.connectivity.rest.provider.ApprovalService&lt;/code&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Reguel Wermelinger</dc:creator><pubDate>Wed, 01 Mar 2017 09:07:47 -0500</pubDate><guid>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#2473</guid></item><item><title>Answer by lttung</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task/2470</link><description>&lt;p&gt;&lt;strong&gt;Scenario&lt;/strong&gt;&lt;br&gt;
- Process A has a HTML dialog &lt;br&gt;
- Process B has a task switch&lt;br&gt;
- If user click a button in HTML dialog, it will trigger process B. =&amp;gt; 1 case of process A and 1 case of process B is created. We do not need the case of process A. &lt;br&gt;
How can we implement without creating the case of process A.&lt;br&gt;&lt;/p&gt;
&lt;p&gt;I follow the guideline of Reguel, inside the callable process I have a task switch. It leads to the error like this:&lt;br&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Caused by: java.lang.IllegalStateException: TaskSwitch element (Role Approval &amp;lt;15A82F10A6717E03-U60-f28&amp;gt;) is not permitted inside a sub process that was invoked from a User Dialog process.
 at ch.ivyteam.ivy.bpm.engine.internal.model.bpmn.TaskSwitchElementExecutorAdapter.checkIllegalTaskSwitchUsage(TaskSwitchElementExecutorAdapter.java:105)
 at 
ch.ivyteam.ivy.bpm.engine.internal.model.bpmn.TaskSwitchElementExecutorAdapter.execute(TaskSwitchElementExecutorAdapter.java:81)
     at ch.ivyteam.ivy.bpm.engine.internal.model.ProcessElement.lambda$0(ProcessElement.java:215)
     at ch.ivyteam.ivy.bpm.engine.internal.model.ProcessElement.executeInElementContext(ProcessElement.java:286)

 at ch.ivyteam.ivy.bpm.engine.internal.model.ProcessElement.execute(ProcessElement.java:215)
 at ch.ivyteam.ivy.bpm.engine.internal.core.ProcessElementExecution.execute(ProcessElementExecution.java:37)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Is there a way to trigger another business process (by using Trigger, Signals, Callable sub,...) from a HTML dialog without persisting the ICase of the current business process?&lt;/p&gt;
&lt;p&gt;Thanks and regards,&lt;br&gt;
Tung&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">lttung</dc:creator><pubDate>Tue, 28 Feb 2017 10:07:47 -0500</pubDate><guid>https://answers.axonivy.com/questions/1905/trigger-activity-no-task/2470</guid></item><item><title>Comment by Stelt0 on Reguel Wermelinger's answer</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#1911</link><description>&lt;p&gt;currently it is Async, but if we decide to make it Sync, I would rather change the process type, as you suggested.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stelt0</dc:creator><pubDate>Thu, 21 Jul 2016 10:08:08 -0400</pubDate><guid>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#1911</guid></item><item><title>Comment by Reguel Wermelinger on Reguel Wermelinger's answer</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#1910</link><description>&lt;p&gt;As long as you do not require a return value from the called process this is also a good solution. Or do you send the result back as signal?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Reguel Wermelinger</dc:creator><pubDate>Thu, 21 Jul 2016 10:04:24 -0400</pubDate><guid>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#1910</guid></item><item><title>Comment by Stelt0 on Reguel Wermelinger's answer</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#1909</link><description>&lt;p&gt;But what if I set the responsible Role to SYSTEM ?&lt;/p&gt;
&lt;p&gt;As a workaround we called process via Ivy Script and Signals so that we did not changed the project type.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stelt0</dc:creator><pubDate>Thu, 21 Jul 2016 09:07:03 -0400</pubDate><guid>https://answers.axonivy.com/questions/1905/trigger-activity-no-task#1909</guid></item><item><title>Answer by Reguel Wermelinger</title><link>https://answers.axonivy.com/questions/1905/trigger-activity-no-task/1908</link><description>&lt;p&gt;If you don't want a task and an asynchronous execution then a Callable Sub Process could do the job better. 
Just put your target process logic in BPM process of kind 'Callable Sub Process'  and invoke it from the Html Dialog by using the (Subprocess) 'Call' Activity.&lt;img alt="alt text" src="http://answers.axonivy.com/upfiles/callableSubProcessCreation.png"&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Reguel Wermelinger</dc:creator><pubDate>Thu, 21 Jul 2016 08:51:39 -0400</pubDate><guid>https://answers.axonivy.com/questions/1905/trigger-activity-no-task/1908</guid></item></channel></rss>