Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Converting Date to text gives unknown numbers?

Featured Replies

I have 2 date fields and a notes field that I have to combine with no slashes or dashes or othe marks (for export into another program)

This is the format I need to export:

mmddyy mmddyy note

This is my calculation field

Action Date & " " & FollowUp Date & " " & Action Notes

This is how the field should look:

020904 021004 client seems to think there is no budget

but this is the result I get

731620 731720 client seems to think there is no budget

--------

I'm guessing that a date format uses some underlying numerical calculation, because I get a similar result in Excel if I change a "date" format to a Text format.

I've tried DateToText, but I still have slashes (and no leading zeroes). If I import into Excel to "find and replace" the slashes, the "dates" changes to that underlying number code.

Any ideas? It seemed like an easy problem, and would be, I guess, if the "date" format wasn't just a mask over other numbers.

Thanks in advance

Cheri

  • Author

I have 2 date fields and a notes field that I have to combine with no slashes or dashes or othe marks (for export into another program)

This is the format I need to export:

mmddyy mmddyy note

This is my calculation field

Action Date & " " & FollowUp Date & " " & Action Notes

This is how the field should look:

020904 021004 client seems to think there is no budget

but this is the result I get

731620 731720 client seems to think there is no budget

--------

I'm guessing that a date format uses some underlying numerical calculation, because I get a similar result in Excel if I change a "date" format to a Text format.

I've tried DateToText, but I still have slashes (and no leading zeroes). If I import into Excel to "find and replace" the slashes, the "dates" changes to that underlying number code.

Any ideas? It seemed like an easy problem, and would be, I guess, if the "date" format wasn't just a mask over other numbers.

Thanks in advance

Cheri

Dealing with converting dates to text can be vexing. I would suggest making two calculation fields (result text) for your two dates. For Action Date:

Case (Month [Action Date] < 10, "0" & NumToText [Month [Action Date]], NumToText [Month [Action Date]]) &

Case (Day [Action Date] < 10, "0" & NumToText [Day [Action Date]], NumToText [Day [Action Date]]) &

Right [NumToText [Year [Action Date]], 2]

The Month, Day & Year functions return numbers. The calc tests to see if they are single digit numbers, and adds a leading zero if so. It also converts them all from numbers to text. This is off the top of my head, so I hope I have the right numbner of open & close brackets.

Call this ActionDateCalc. Make a similar field for FollowUpDate. Stick both calcc fields off on an All Fields layout where they don't need to be seen. Alter your concatenation above to;

ActionDateCalc & " " & FollowUpDateCalc & " " & Action Notes

That should do it.

Steve Brown

Dealing with converting dates to text can be vexing. I would suggest making two calculation fields (result text) for your two dates. For Action Date:

Case (Month [Action Date] < 10, "0" & NumToText [Month [Action Date]], NumToText [Month [Action Date]]) &

Case (Day [Action Date] < 10, "0" & NumToText [Day [Action Date]], NumToText [Day [Action Date]]) &

Right [NumToText [Year [Action Date]], 2]

The Month, Day & Year functions return numbers. The calc tests to see if they are single digit numbers, and adds a leading zero if so. It also converts them all from numbers to text. This is off the top of my head, so I hope I have the right numbner of open & close brackets.

Call this ActionDateCalc. Make a similar field for FollowUpDate. Stick both calcc fields off on an All Fields layout where they don't need to be seen. Alter your concatenation above to;

ActionDateCalc & " " & FollowUpDateCalc & " " & Action Notes

That should do it.

Steve Brown

  • Author

Thank You - I was going to drop in the calculations for leading zeroes and the 2-digit year AFTER I solved the problem of turning a date into text - I didn't realize that the calculations themselves would solve the problem!!

Thank you so much for taking the time to answer!

Cheri

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.