Does anyone know how to create an event in visual workflow - i know how to create the record i am just having issues creating the date time piece as you can not create datetime fields in VWF.

At the moment i have a picklist of times and a date field, i want to try and concatenate these and add in the rest of the values as if i was using the apex data loader but having issues doing this


3 Answers 3


It's quite a long-winded approach, but I created a number of formula fields to cater for each of the datetime components and concatenated them together in a string.

YearFormula = YEAR({!RequiredDate})
MonthFormula = MONTH(...)

For the time component, I used:

TEXT({!Time}) & ":00:00"

where Time is the picklist value, which I exposed as a number.

The final step is to pull it together in another formula:

DATETIMEVALUE(TEXT({!YearFormula}) & "-" & TEXT({!MonthFormula}) & "-" & TEXT({!DayFormula}) &" " & TEXT({!Time}) & ":00:00")

On record creation, the value of the formula is written to the Datetime field.


You should be able to do date/time fields as of Spring 14. Just create a new variable like normal and choose DateTime as the variable type.

You should be able to use an Assignment element to "add" the data together, which will essentially perform a concatenation. You may need to also define a constant with a default value of " " (a space) to be between your date and your time, also concatenated in.

  • yes, there is a DateTime variable, i am just not sure on how to concatenate a date and a time to go in there as it only accepts date fields. at the moment i have a date field and a time field, i can get the date into the field, i just dont know how to manipulate the time Commented Apr 25, 2014 at 20:59

I strongly suspect the answer to your question is very similar to one that was just posted and answered a day or so ago titled Can we do custom datetime in visual flows? The methods you need were outlined in that post.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .