• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: last day of the month of a date
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: last day of the month of a date


  • Subject: Re: last day of the month of a date
  • From: bill <email@hidden>
  • Date: Thu, 15 Dec 2005 12:28:12 +0800


I'd like to get the last day of the month of a date, say current date. The only "simple" way I found to get it is : (here adate is a valid date)

Depending on the definition of "simple" ;) you may find this one-liner:

tell theDate to 32 - ((it + (32 - (its day)) * days)'s day) returning x

which first appear in the thread "Number of days left in the month" in 2002. I guess most people on the list can guess who is the author, if not, have a look at:

<http://lists.apple.com/archives/applescript-users/2002/Nov/ msg00831.html>


bill

Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Set hours of date = stack overflow error on 10.3.9?
  • Next by Date: Loading Print Styles in Quark?
  • Previous by thread: Re: last day of the month of a date
  • Next by thread: Re: last day of the month of a date
  • Index(es):
    • Date
    • Thread