Tap Forms – Organizer Database App for Mac, iPhone, and iPad › Forums › Using Tap Forms › Calc Field: Adding Days to Date Field
- This topic has 7 replies, 3 voices, and was last updated 5 years, 10 months ago by Brendan.
-
AuthorPosts
-
January 31, 2019 at 11:57 AM #33596
mrbillParticipantHowdy- Hope you’re well.
I know this is something I’m doing wrong and searched the forums to try and figure this out, but I getting the same output.
Within a table field, I’ve created a few ‘sub’ fields. One field inside the table is ‘ship date’. Another is number of days shipping, and the third is a calc field that is suppose to calculate the date of arrival. But, I’m getting years, months, etc… Here’s what I’ve done:
1. Designated the ship date field as a date
2. Designated the ship time as a number
3. Designated the Arrival as a calc. Then within the calc, I’m using the following formula:DATEADD([Ship Date]; 0; 0; 0; [Ship Days]; 0; 0; 0). I’ve also played with the formatting of the the calculation field to ensure its formatted as a date. Example: Number format: Time (years, months, days and date format Jan, 12, 2019
But the calculation field is showing 49 years, 1 month, 18 days.
Any thoughts? Many thanks!!
– BillJanuary 31, 2019 at 12:31 PM #33598
BrendanKeymasterHi Bill,
Set the Number Format to No Format for your Calculation field. Set the Return Type to Date.
It looks like it’s using the Time (years, months days) Number Format setting right now.
The DATEADD() function should return an absolute date value.
Thanks,
Brendan
January 31, 2019 at 12:42 PM #33599
mrbillParticipantHey Brendan- Thanks as always for the quick attention.
Ok, I set the Number format to ‘No Style’ (returned a string of digits). Can you explain what you mean below by ‘Return Type to Date’. Just in case it helps, I’m enclosing a screen snap. As an FYI, Calc will be the field that will display the arrival date.
Thanks!
– BillAttachments:
You must be logged in to view attached files.February 2, 2019 at 4:58 AM #33610
Gianantonio FiannaccaParticipantType result have 3 little icons: you have to select the last to right.
I created a little example,
By
GianantonioAttachments:
You must be logged in to view attached files.February 2, 2019 at 9:47 AM #33613
mrbillParticipantThank you! I found what you are talking about. Its within the calculation section. Works like a charm. Thank you both Brendan and Gianantonio.
Works great. Thanks!
– BillFebruary 2, 2019 at 2:08 PM #33619
BrendanKeymasterHi Bill,
I’m glad that Gianantonio and I were able to help.
Gianantonio was referring to the iOS version by the way with the 3 little icons. They look like a 3, a T, and a little calendar icon. It’s the equivalent of setting the Result Type on the macOS version’s popup button.
February 2, 2019 at 7:35 PM #33632
mrbillParticipantThanks. Ya, I couldn’t find the icons, but assumed it something along those lines and found the drop-down. But ya, all working.
Only strange thing is that when I choose date format of either <default> or medium, it still showing the time. I ended up just choosing M/DD/YYYY and it then removes the time.
Thanks!
– BillFebruary 2, 2019 at 8:23 PM #33638
BrendanKeymasterThat’s right. The short, medium, long, and full ones do show the time regardless of the time setting. Those ones are sort of special cases and the format of them are controlled by the Dates tab on the Advanced panel on the Language and Region System Preferences panel.
-
AuthorPosts
You must be logged in to reply to this topic.