specifying how to save file

Hi all, i’m triggering a program (a card game) to run which only saves the results of the game as a file called “output.txt”. I’ve only just started using PsyScript (a research-focussed version of AppleScript) so am a complete novice. So if anyone’s able to suggest a code to try that will save the results of the game under a specified name and location, I would be very appreciative!

Mem

I don’t know what app you’re speaking of, but you probably can’t “trigger” the game to run. More than likely, you are telling the system to run it. Once the game is running, it would have to be “scriptable” in order for you to have an way to save a game state. I don’t know of any card games that are scriptable. Some otherwise unscriptable applications can be scripted via “UI” scripting if they use plain-vanilla cocoa calls to create their interface.

Thanks for your reply. The code I use to run the card game (used in psych research) is very simple:

tell application “cardgame”
activate
end tell

If I can’t change the name or location is saves to, can I write a code to move the “output.txt” file from the location saves to by default, into the a location I specify? I imagine this is really simple so please pardon my ignorance.

Thanks in advance,