The error, "Invalid Date" (or the error "Destination does not contain a number") occurs because the old script creates a long date in which the day name does not match the day number. Such as:
Sunday, September 12, 1992
(The correct day name for this date is Saturday)
While HyperCard 1.x could correctly convert such a mismatched long date to another date format (it ignores the day name), HyperCard 2.x will see the date as invalid, and exit the script with an error.
To correct the issue:
1) Go to the background script of the calendar stack, and find the function startOfMonth.
2) Find the first line reading "Convert it to long date", and change the words "long date" to "dateItems". (Note: dateitems is one word.)
3) Change the next line
put 1 into word 2 of item 2 of it
to
put 1 into item 3 of it
Note: The dateItems format shows the date "Saturday, September 12, 1992" as "1992,9,12,0,0,0,7"
(The parameters are "year,month,day,hours,minutes,seconds,day of week")
This article is adapted from the Claris Tech Info database.