Hello everybody,

I'm using this function (which I found elsewhere in this ng, thanks) in
an entity create.

--- CUT HERE ---
function setDateTime1() {
convert date from entry on workflow to eDirectory format
date or datetime picker is used to pick the date
var edirFormat = new java.text.SimpleDateFormat("yyyyMMddhhmmssZ");
var workflowFormat =
new java.text.SimpleDateFormat("yyyyMMddhhmmssSSSZ");
try {
var tempDate = workflowFormat.parse(flowdata.get('begindate'));
} catch (err) {
return err
return edirFormat.format(tempDate);

---- CUT HERE ---

The date comes from a picker in a create form in an autoapproval workflow.
It works nicely, and is written correctly to edirectory.
I would like to subtract at given amount of time from 'begindate', say 12
hours, before it hits the directory. I can't figure out how to do that,
can anyone help me?