Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

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

Recommended Posts

  • Newbies
Posted

I'm sure this is a very simple question; I just haven't found the answer.

Once I have the path to a file, how do I use ScriptMaster to open the file with it's native app?

Posted

Here's one way

Would be interested to see how others might do it.

Needs Java 1.6 - so won't run on OSX 10.5 or less




// FileOpen ( fm_fileIn ))

// 12_02_22 JR

// v1.2

// open any file in registered desktop application





import java.awt.Desktop

if (java.awt.Desktop.isDesktopSupported()) {

desktop = new Desktop()

try {

  desktop.open(new File(fm_fileIn))

} catch (e) {

  return e.getMessage()

}

return true

}  else {

return 'ERROR'

} //end if



Posted

John - I find your version to work just fine (at least on the Mac). In particular, it's nice that it also works to reveal a folder in Finder if you send a folder path and not a file path.

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