cancel
Showing results for 
Search instead for 
Did you mean: 

Don't script tasks with print command work?

ale83_webmaster
Champ in-the-making
Champ in-the-making
I'm starting to use Activiti for my degree thesis.
I've created a symple Hello world! example of process like the one explained at pag. 37 of the book "Activiti in Action", with only a start and an end event and in the middle a script task where I've inserted the following Groovy code:
out:println "MESSAGE";
.
I've designed it in Eclipse and then I've deployed and run it in Activiti Explorer, but, when I do this, after the message "Process myProcess has been started" nothing more happens. Is it normal? Shouldn't it show to me the message I've written in the command on the screen?
I've tried also to use the code
System.out.println("MESSAGE");
instead, but anything change. I've also tried to use Javascript instead of Groovy, but then I see the following warning message when I run the process.
[img=750x68]http://i.imgur.com/6hCk0bv.png[/img]
3 REPLIES 3

ale83_webmaster
Champ in-the-making
Champ in-the-making
I've solved myself the problem printing the message I wanted to be shown in a file.
This simply with the command: <code>new File('/path/name_of_the_file.txt') << "text of my message"</code> and then I have a text file with the message printed into it.

Because I don't find a console where the messages were printed into, I think this is better than nothing…

smirzai
Champ on-the-rise
Champ on-the-rise
you can also try this:
java.lang.System.out.println("HELLO")

smirzai
Champ on-the-rise
Champ on-the-rise
or even simple print("sssl") in newer versions.