Jump to content
Server Maintenance This Week. ×

using applescript to pass a filename to Filemaker as variable - import records


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

Recommended Posts

HI,

I have an applescript that selects the name and path of an XML file that id like to then parse into filemaker.

I have tried using "Set Variable" to do this but cannot make the link between the applescript and $VariableName.

It is currently not working and is hard to find any examples on the web.

Any help is much appreciated.

It would look something like this. (which is SO NOT working)

Filemaker Script

Perform Applescript:


global file2open

set file2open to (choose file)

set file2openName to POSIX path of file2open

set $theFile to file2openName

Set Variable: [$FileToImport; Value: "filemac:/"& "$theFile"]

Import Records: [No dialog; $theFile; myxslt; Add; Mac_Roman]

Link to comment
Share on other sites

Thanks Karsten,

That looks promising, a little backwards yes, but it looks like the only option.

How do I then bring that field in you demo back into the "import fields" dialog as the file path to import?

Cheers

Link to comment
Share on other sites

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