• Hello MLAers! We've re-enabled auto-approval for accounts. If you are still waiting on account approval, please check this thread for more information.

Apple Script Professionals here?

avw

6502
I am new to Apple Script, but the following script should be possible. The recorder doesn´t help me:

open the date control panel,

change the year to 1996

close the control panel

Open a application in the same folder as the script (with fixed name)

open the date control panel again

and restore the original (recent) year

Any ideas how to do this?

 
What you want to accomplish should work at least from System 7.1 on. Such script could be used to spoof a modified current date for helpful purposes. In case a software only checks once for the current date, you even might include another script to restore the actual date after starting some software. This is useful to keep consistant creation dates of documents. Unfortunately the last time I used such command was at least 10 years ago, so I have no tutorial at hand, just a few hints:

If you cannot script the date control panel, it might just have no scripting interface. Instead look for a command to directly set date and time. If not available by default, look for Scripting additions (OSAX) to provide the command in need. Another nice tool to extend the scripting capabilities of any old Mac is the software KeyQuencer, which provides a scripting interface to include KeyQuencer capabilities into AppleScript scripts (like: waiting for some window to open, click into a specific location of a window and perform nearly each thing you could do with keyboard and mouse.

 
Back
Top