Software Venture Consulting

FileMaker Pro downloads & Resources
FileMaker Custom Functions
FileMaker Web Viewer Examples
FileMaker Pro & Lasso Consulting
Training
FileMaker Books
FileMaker Articles
FileMaker Error Reference

Free Web Tools
Free FileMaker Tools

Personal Pages
Videos
Adventures
Links

Shopping Cart
Shopping Cart

Search:

Free Newsletter
Signup


Contact


Privacy Policy



FileMaker is a registered trademark of FileMaker, Inc. in the U.S. and other countries.

 

 FileMaker Pro Custom Functions

List  |  Show Random  |  Upload  |  Add This to Your Site

fnOneMonthEarlier(DateFrom)

Rate this function:  

RatingRatingRatingRatingRating
  Average rating: 4.4  (21 votes)
  Discuss this Custom Function

Maria del Rocio Moguel, UT MD Anderson Cancer Center
http://www.mdanderson.org

Gives the exact date of one month earlier

Sample Input:
fnOneMonthEarlier(1/31/2015)
Sample Output:
12/31/2014


 Then copy & paste into FileMaker Advanced's Edit Custom Function window.

Click here to copy To Clip Manager if you have myFMbutler's Clip Manager installed

Description:

This function takes into account the different lengths of the months (30, 31, 28) so in case the day number of the DateFrom is 31, it will place the correct day number for the previous month. (It does not take into consideration a leap year; it will use Feb 28).

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

This is my Custom Function and I want to edit it

Discuss:

5 most recent comments | Show all 9 comments

Here is another one.
http://www.briandunning.com/cf/5
put -1 as months parameter get the result you want.

and simplify it

Let(
guess = Date(Month(startDate) + months; Day(startDate); Year(startDate));
guess - Case ( Day (guess) <> Day (startDate) ; Day ( guess ) )
)

unix, Japan
April 13, 2015 5:25pm

Yes, Bernand Moreau. Thank you for noticing. I corrected it.

Rocio, Houston, TX
April 14, 2015 5:49am

What is purpose of this function?

Enter 10/31 returns 9/30
Enter 10/30 returns 9/30
Enter 3/31 returns 2/28
Enter 3/30 returns 2/28
Enter 3/29 returns 2/28

Lesser days do return the same day in the prior month.
I just don't see a practical use. Explain.

Jeep Watson, Baltimore, MD
April 14, 2015 9:36pm

Jeep Watson, I created the function because I need to send some paperwork one month before the due date (not just 30 days each time). If the due date is October 31 or October 30, the function will give me September 30 because September only has 30 days. It would be incorrect to have 9/31. The same happens for March; if the due date is the last day of March, I have to send the paperwork the last day of February, which only has 28 days.
This function may not be useful for you if you don't have a similar scenario, but at least, it works for my situation.
Thank you for your comments.

Rocio, Houston, TX
April 15, 2015 5:52am

Hi, I would like to keep the invitations in my inbox so that I can later secarh & find them. (otherwise, we will need a secarh engine which also indexes the calendar).In current v3.1.3, when I accept an invitation, it is deleted from my inbox. I could not find an option not to do it (Outlook has such an option).Thanks.

Samuel, k9ZgA5ytGf
November 27, 2015 10:11am

Make a comment about this Custom Function (please try to keep it brief & to the point). Anyone can post:

Your Name:
City/Location:
Comment:
characters left. If you paste in more than 1500 characters, it will be truncated. Discuss the function - advertisements and other useless posts will be deleted.
Answer 6 + 9 =
Search for Custom Functions:

Custom Functions Widget
Download the Custom Function Dashboard Widget for OS X
Keep all the latest Custom Functions right at your fingertips!

Newest Custom Functions:

1. ProperAllWords ( text )
  (Thu, Dec 14, 5:19pm)
2. MatchExist ( SourceTable.Field ; DestTable.Field ; ReturnField )
  (Thu, Dec 14, 1:07pm)
3. BVR_Format ( bvr )
  (Wed, Dec 13, 5:32pm)
4. NumberToHexadecimal(NumberValue)
  (Fri, Dec 08, 8:54am)
5. Get_BaseTable
  (Thu, Dec 07, 4:27pm)
6. JSONCreateVarsFromKeys ( json ; namespace )
  (Wed, Dec 06, 8:21pm)
7. GetTableNzme ( field )
  (Tue, Dec 05, 9:16pm)
8. TimeFormatAsText ( theTime )
  (Mon, Nov 13, 1:59pm)

RSS Feed of Custom Functions