Maybe you can just rely on Calendars, which provides Calendar#getMaximum(Calendar.DAY_OF_MONTH)

It is not really reinventing the wheel, just using the available api and combine


Steve Swinsburg a écrit :
Hi all,

I am creating a set of dropdown choices for a user to enter their birthday on a profile. One for day of the month, one for month of the year, and one for year. However I want to be able to take into account months that have differing numbers of days, (ie some 30, some 31, some 28, every now and the 29 etc) which is all dependent on the month and if its a leap year or not.

Does anyone have a component/fragment of code that handles this already to save reinventing the wheel?



cheers,
Steve








---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to