June 12, 200817 yr My brain is foggy today and am reaching out for help. How do I calculate the date (dd/mm/yy) for the first day of the month previous to the current date? Examples: Current Date = 6/12/08 Result 5/1/08 Current Date = 1/20/08 Result 12/1/07 I will be writing a script to find all the records in my database for the previous month. I have found custom functions for calculating the last day of the previous month but am stumbling on the best way for getting the first day of the last month. Thanks to all who reply Rich :)
June 12, 200817 yr I have found custom functions for calculating the last day of the previous month Custom function is not required for this either. Date ( Month ( Get ( CurrentDate ) ) ; 0 ; Year ( Get ( CurrentDate ) ) ) or even ... Get ( CurrentDate ) - Day (Get ( CurrentDate ) )
Create an account or sign in to comment