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 6742 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted (edited)

The following script works in Filemaker Pro 8

Go to Layout {"InvoiceViewer"(Invoiceviewer)}

Show All Records

Delete All Records[]

Send Event ["aevt", "odoc"; "cmd/c dir /b M:FolderfolderPDFfolder >c:outputfile.txt"]

Pause/Resume Script [Duration(seconds):5]

Import Records["outputfile.txt";Add; Windows ANSI]

Show All Records

But when I create a runtime it fails with the following message:

The file "outfile.txt" could not be found and is required to complete this operation

If I hit the OK button it allows me to select the file and the script continues.

It worked in the previous runtimes I created.

Any ideas?

Edited by Guest
Posted

That's odd. I created the runtime on an XP computer and deployed it to a Windows 2000 computer. Works fine on the Windows 2000 computer but not on the XP computer. Got to be a system problem but what??

I know the XP system is set to do automatic updates, I wonder if that has something to do with it?

Posted

It fails on the import step, right?

how's that file reference defined?

file:/c:/outfile.txt

Sounds like the runtime machine doesn't have enough time with the 5 seconds to finish the text file before the import script needs it. When you use the manual dialog you can see the file because the OS has now finished writing to it...

Posted

Probably Pilot Error :)

It fails on the import step, right?

Correct

how's that file reference defined?

file:/c:/outfile.txt

For some reason i thought you had to have a file created already. So I created a file and when I selected the file I got the following listing in the File Path List:

file:.../../../../outputfile.txt

But now when I typed in the reference (as you described above): file:/c:/outputfile.txt

It works like a charm. And creates the necessary file.

Thanks Wim

Posted

You're welcome.

The .../.../... indicates a relative path with the starting point being where the FM file is. In your case it basically says "go up 4 levels from where I am". When you move the file that is likely to break.

hard coding the location works wherever the file is.

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