August 12, 201114 yr I'm struggling with formatting the date correctly ... I need the date and time to come up in a calculation with leading zero's in it. I can make it look right in the record via the formatting functions, but when I try and take the date or time from that field and combine it within a calculation, it's dropping the leading zero's. Same thing happens when I use the getdate function. I have a script that strings it all together to form a file name, and I have to keep the zeros. What am I missing? example: I need the timestamp (or a date and time field) to output 08_04_11 for August 4, 2011, not.... 8/4/11. Thanks for any guidance... steve.
August 12, 201114 yr Try = SerialIncrement ( "00" ; Month ( YourDate ) ) & SerialIncrement ( "_00" ; Day ( YourDate ) ) & SerialIncrement ( "_00" ; Mod ( Year ( YourDate ) ; 100 ) )
August 12, 201114 yr Author It's like magic... thanks for waving your wizards wand my way. Can I do the same thing with the time field? Replace "month" with "hour"? etc...
Create an account or sign in to comment