Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 7009 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted (edited)

Howdy Folks,

I am rejoining the world of Filemaker development. It was pretty much my full time job back in the FM5 days and I kept my hands in with little projects for friends over the years. I was even using filemaker when it was owned by Nashoba Systems.

Anyway, having talked about my experience level, I am emberassed to ask the following question.

How do I simply add some number of days to a date?

I have a date field,number field and a calculation field. Just adding the date and number fields together in the calculation field does not do it. I have tried using the function DayOfYear(DateField) and adding it to the number but this does not work. It feels like I should be converting the number into a date friendly thing, but I cannot see a way to do this.

I have solved this issue before but just can't recall how I did it.

Sorry for being such an inexcusable bonehead.

Any help appreciated.

One strange bit of information is that this particular calculation was working fine in FM7. I just looked at a runtime I had made of it and its working there.

Very strange.

Edited by Guest
Got new info.
Posted

Just adding the date and number fields together in the calculation field does not do it.

Yes it does. Just make sure the result of the calculation is set to Date.

Posted

Ok.. its working.

I created a new calculation field with the same parameters and for some reason it works while the other does not.

Anyone else had FM8 do anything funky to fields in solutions created in FM7?

The thing that has me scratching my head is that the FM7 runtime with this calculation works fine.

Thanks for the help.

Posted

Runtimes are the same engine as the full versions.

There is something else that is wrong here. First of all, DayOfYear just calculates the day of the year for that date. i.e., 11/19/2005 is the 323 day of this year.

Sometimes calculating a future date can be as easy as just adding your number of days to your date field like this:

DateField + 5

or two fields, such as a Date Field and a Number field.

DateField + NumToAdd

HTH

Lee

This topic is 7009 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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