November 12, 200223 yr I'm having difficulty entering data from the script(date) into a date field of FMP. Is there a solution? Mariusz
November 13, 200223 yr Here is a subroutine that will take the AppleScript date and convert it to a text string that FileMaker will interpret as a date. It will automatically adjust for US or European time formats. [ A complete description of the subroutine can be found at http://www.macadillo.com/ATW/shortdate.html ] on FormatDate(theDate) set thisDay to text -2 thru -1 of ("0" & day of theDate) copy theDate to b set month of b to January set thisMonth to text -2 thru -1 of ("0" & (1 + (theDate - b + 1314864) div 2629728)) try word 2 of (theDate as string) as integer -- will error on US date format set theFirstPart to thisDay & "/" & thisMonth on error set theFirstPart to thisMonth & "/" & thisDay end try set theShortDate to theFirstPart & "/" & (year of theDate) as text return theShortDate end FormatDate
Create an account or sign in to comment