-------- Original Message --------
Subject: i have on question
From: Alexandre Priou <[email protected]>
To: [email protected]
Date: Tue Feb 22 2011 21:18:09 GMT+0100 (CET)
> hi
>
> it's possible to open a dialog box in the ant task ?
> i need an answer for continued to run one task, it's possible ?
>
> thanks for your answer
for simple purposes it may be sufficient to use the builtin <input> task
or something like :
<script language="beanshell">
import javax.swing.*;
int decision = JOptionPane.showConfirmDialog(null,
"Please decide ...", "choose one", JOptionPane.YES_NO_OPTION);
if (decision == JOptionPane.YES_OPTION) {
// User clicked YES.
} else if (decision == JOptionPane.NO_OPTION) {
// User clicked NO.
// using fireBuildFinished didn't work
// project.fireBuildFinished(BuildException e);
stop = project.createTask("fail");
stop.setMessage("No selected ... ");
stop.execute();
}
</script>
in your script, before writing a new task.
also you may use - or get inspired by - Ant Forms :
http://antforms.sourceforge.net/
and finally you may implement your own input handler :
http://ant.apache.org/manual/inputhandler.html
Regards, Gilbert
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]