Simple Example for Script Task

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-23-2016 03:50 AM
Hello Team,
I am trying Script Task. I am just trying basic usage of Script Task without any use case yet.
Just to know how it works.
I tried
It got deployed. But when i start the Activiti. It throws an error alert is not a keyword.
Can you please provide some simple example so that i can just paste and run the activiti workflow?
Regards,
Chandan
I am trying Script Task. I am just trying basic usage of Script Task without any use case yet.
Just to know how it works.
I tried
<scriptTask id="sid-AD08CD49-08D0-4910-9912-BB7C73637844" name="Script" scriptFormat="JavaScript" activiti:autoStoreVariables="false"> <script><![CDATA[alert("Welcome to activiti Javascript")</script>]]> </scriptTask>
It got deployed. But when i start the Activiti. It throws an error alert is not a keyword.
Can you please provide some simple example so that i can just paste and run the activiti workflow?
Regards,
Chandan
Labels:
- Labels:
-
Archive
3 REPLIES 3
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-23-2016 05:16 AM
Hi Chandan,
e.g.
in activiti source.
Regards
Martin
e.g.
org.activiti.examples.bpmn.scripttask.ScriptTaskTest
in activiti source.
Regards
Martin
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-24-2017 03:03 AM
Hi Martin,
I am trying to use alert but am unable to get alert box, so kindly provide script task example.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2017 08:06 AM
Hi Chandan
Alert is not available, it's not web browser script. Use something else, a bit less user-interactive.
You can import and use java classes if you want to write something to logs, for example.
