Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6201 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted (edited)

Hello, this is too easy to find an answer to! I've been searching for an hour or so for this simple script. I've only been able to find really complicated and special situations...

Obviously I've never used applescript before.

I have datbase that stores file references to MS Word documents (in contianer fields, of course). I'm creating a loop script to print out the document in a certain order.

So I need a very simple script that will print the MS Word document, then close it. That's all.

I can specify the filepath dynamically in the "Perform AppleScript" script step in FMP.

Thanks!

Edited by Guest
  • Newbies
Posted

I figured it out :smile2: ... I put this calculation into the "Perform AppleScript" script step:

"

tell application "Finder"¶

	activate¶

	print document file "" & Substitute ( GetValue ( fm_database_name::field_with_file_reference ; 2 ) ; ["filemac:/" ; ""] ; ["/"; ":"] ) & ""¶

end tell

"

And it works perfectly. However, it still displays the print dialog, which is fine, but I'd like to know how to prevent that. Does anyone know? Or is AppleScript a soon to be forgotten language?

This topic is 6201 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.