Highlighted

Problem calculating difference between dates

Avatar

Avatar

mdawn50

Avatar

mdawn50

mdawn50

16-03-2011

I have two date fields Current date and Hire date. I also have a difference field.

The Current date is calculated and is displayed as 3/16/2011.

However, the hire date is displayed as 03/01/2011. Nothing is displayed in the difference field. However, if I remove the leading zero from the Hire date field, I get the correct difference.

How do I control the leading zero in one or the other date field?

Thanks,

MDawn

Replies

Highlighted

Avatar

Avatar

radzmar

MVP

Total Posts

(val/1000)?string[".0"]}K

Likes

385

Correct Answer

485

Avatar

radzmar

MVP

Total Posts

(val/1000)?string[".0"]}K

Likes

385

Correct Answer

485
radzmar
MVP

16-03-2011

Hi,

the look of a date can be controlled by a pattern.

date{M/D/YYYY} = 6/2/2011

date{MM/DD/YYYY}  = 06/02/2011

Highlighted

Avatar

Avatar

mdawn50

Avatar

mdawn50

mdawn50

16-03-2011

I'll try that.

Thanks,

Margaret Dawn

630-850-1065

Highlighted

Avatar

Avatar

mdawn50

Avatar

mdawn50

mdawn50

16-03-2011

The pattern worked to control the leading zero. Now I've discovered that the calculation works if I type the date directly in the field, but doesn't work if the date is

selected from the calendar icon.

Thanks,

MDawn