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

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

Recommended Posts

Posted

I'm trying to open up a pdf file with "send apple event," and though Acrobat Reader will open, the particular file specified in the path does not open. I can open up a Word file with "send apple event," and even a jpg, but not a pdf. Any suggestions?

Posted

Maybe the file doesn't have the appropiate creator type or three letter extension. You can use AS to directly open the file in Acrobat.

Posted

The file does have the right extension and creator type. I need to script it so that the particular file that gets linked (in the field "file path") gets opened.

  • 4 weeks later...
Posted

Never found a solution to the previous query -- but here's another puzzler.

I'm using "send apple event" to open Microsoft Word files (path is specified in a field). Most of the users don't have a problem. BUT I have a couple of users (on FMP 5.5) who get a weird error message if Word isn't already opens (it works fine if Word is already open). It's not a problem specific to 5.5, since some of my 5.5 users don't have a problem. When I look at the script on the problem computers, the target application is missing (but not on the other users' computers). When I specify the target application, it doesn't do anything (I'm assuming it's because it's a server version). What's going wrong? All the users are on OS X, not sure about the version of Word.

There's a bonus for anybody who can also tell me whether and how you can use Microsoft Word's mail merge function with a hosted file...

  • 2 weeks later...
  • Newbies
Posted

Instead of using the send apple event script step you should use the following applescript:

try

copy cell "gLaunchFilePath" of current record to filePath

tell application "Finder" to open filePath

on error errmsg

activate me

display dialog errmsg

end try

Make sure that the "gLaunchFilePath" is the field with the full file path (including file name & extension). This should open the file with the default program for that extension type.

I use this all the time in my solution, hope this helps!

This topic is 7436 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.