Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Export Records

Featured Replies

  • Newbies

I have over 3000 records with 10 fields to archive from 2 different layouts, however some of the field names are different. The archive file name is unique for each day and I have written the script to generate the name from various elements of the records. Is there anyway to automatically set up the field export list so that it is correct for the records I am exporting and also automatically allocate the file name and path to the dialog box. Phew, I hope you understand that. I have only been working with filemaker for 3 months here in the UK

Many thanks

FileMaker pro remembers the last export order (as it does the last find and sort).

Perform the export, the create a script with the export command in it (set to restore export order and no dialog). There, it's saved.

Now do the same for the other export: make a different Script.

  • Author
  • Newbies

Thanks Vaughan, Many thanks for your reply.

I asked 2 questions although reading my mail it was not that clear for which I apologise.

The second question concerns the dialog box where you enter the file name and location on the selected drive to store the exported records.

Is there any way to set the filename box and location box automatically from a script?.

I have added a Copy function to my script which copies the filename ok, but the Paste function does not work even though the cursor is blinking in the filename box.

Doing a Ctrl V does put it in, so why not the paste?.

The exported records are always going to be archived in the same location so I was trying to find a way for Filemaker to remember that. There are several users across the network who can archive so I wanted it to be finger proof so that the correct location is always chosen.

Again Many thanks, I,m learning everyday.

No, file names (and alert messages) are not copy/paste-able, nor can they be based an the contents of a field.

Many people work around this limitation using AppleScript or WinBatch -- save to a temp file, rename the temp file to whatever is needed.

I just reread your question: the file name and location is saved in the script, it's just that it cannot be changed. That is, the script will always save to the same name and location. I've always wanted FMP to save files with date/time appended to the name, but it cannot be done in FMP, outside help is needed in the form of AppleScript or Winbatch.

[This message has been edited by Vaughan (edited November 29, 2000).]

  • Author
  • Newbies

Thanks Vaughan,

Below is the script I wrote to set the filename for each day. Then end result is a file name BU121100.00W,(I,m using the English date format dd/mm/yy). The copy function does save it to the clipboard and when the dialog box appears I manually hit Ctrl V and it pastes it automatically into the file name box that appears as a result of the Export Function.

Script:

Insert Current Date[field name1]

Set Field [field name1,NumToText(field name1)]

Set Field [field name2, "BU"&file name1&".00W"]

Set Field [File name2, Substitute(File name2, "20", "")] #This gets rid of the 20 in the year 2000.

Copy[file name2]

Export Records

I don't know if this is a long winded way to do it as as I said I have only been working with filemaker for 3 months.

Many regards

Dave Tolley

Sure, you can manually copy/paste anything into a save dialog box. But you cannot get a script to do it automatically. And for me, that's the point of scripting, to get stuff done automatically.

  • Author
  • Newbies

I can't agree more, many thanks for your help

Dave

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.