So I'm developing our first Nintex Form and Workflow to allow staff to apply for Annual leave. On my form I've a repeating section to allow multiple types of leave ie 2 days of Annual Leave with 2 day of Sick leave on one form. The Date field on my form is format as Date only.
in my workflow I'm getting the xml from the repeating section and putting field into a collection. Then I loop through the collection and trying to put the data into a Date & Time variable but the workflow keeps coming back with the following error "Data type returned from the collection is incompatible with the variable to store the result in."
It works fine if I store the data into a Single Line of Text Variable but i need to keep the date as Date and Time. Is this possible?
It's possible that i doing this completely wrong as this is our first workflow but I need to change the date so that is display dd/MM/yyyy in a email that gets sent. When I use the Log to History to output the date it's coming back as 06/08/2015 00:00:00
So in my workflow I got the standard Query XML to parse the repeating section into some collections variable, and then I do a For Each, looping through each collection and outputting to a text variable ( I tried a data time one but it didn't like it)
How I have setup the Collection operation. First Day of Leave is a string value. I tried Date Time variable but workflow would stop with an error Data type returned from the collection is incompatible with the variable to store the result in
Then I use a Regular Expression to just get the date,
Then I use a Convert Value so that it can convert the string back into a Date so that I can use the Format-Date Function to format the date as dd/MM/YYYY
you are getting this error because "ColFirstDayOfLeave" have some null values too along with the "First DAy Of Leave" dates and when you assign those null values in "First Day Of Leave" variable which is a DateTime variable I assume, will start creating problem, so make it sure that ColFirstDayOfLeave doesn't get any null values in it. thanks Muhammad Mavia