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

Recommended Posts

Posted

With RalphL's help, I've been able to write a script that uses GTRR (using the related records only check box) to then print out items using a different layout.

Only problem is, there are many times during the day that the script returns no records, even though the layout has a portal showing the correct related records.

Re-running the script does not help, exiting that layout and returning to the same layout and re-runing the script does not help either.

Restarting FileMaker on the client and re-running the script returns the correct records.

All Macs are running Mac OS X 10.3.9 and we are running the database on FileMaker Server 7.0.3 and each client has FileMaker 7.0.3

The issue has happened on at least 3 of our 6 macs running the database.

Am I seeing a 'caching' issue between the server and the clients ?

Thanks in advance

Darrin.

PS: I do not have an issue if I change the script to find the records, rather thn use GTRR . . .

Posted

Have the related records been committed before the GTRR step is activated?

Posted

Make sure the GTRR uses the exact same Table Occurrance (relationship) that the portal is using, and it is the same TO the print layout is based upon.

Posted

Thanks for your posts . . .

I've simplified the layout so there is no portal.

The script is trigged by a user clicking on a button to print from a different layout than the data entry.

Here's the GTRR Script:

Get related records from : <Same TO>

Show record using layout: <Different layout> Show only related records (selected)

Print Setup []

Enter Preview Mode []

Set Zoom Level [150%]

Print []

Go to layout [original layout]

Enter Browse Mode []

The script can run OK for days, then if fails, and continues to fail.

The preview, and the printed page have the field names, but there is data in the fields.

Going to a different record, then back again does not help.

Closing the database, and re-openning solves the issue.

I can put a commit records at the start of the script, but I don't see how that can help.

Does anyone have any futher thougths ?

Darrin.

Posted

The reason I asked is that related records are not committed (saved) until their parent record is committed.

I'm a bit confused on your GTRR step. Can you post a clone or sample of the the file?

Posted

I'm putting together a sample . . .

In the meantime, I see I have three options (I know of) for the first part of the script:

1. Go to Layout.

This is the simplist, where the user stays in the same record of the current set of records but the print layout is called for printing. Right now, due to FM not holding the printer presets in Mac OS X, and the users are new to FM, they are having to manually chose their printing options, and are either printing the first record, or all current records being browsed. I am in the process of adding the Applescripts to set the printer presets for FM.

2. GTRR.

This allows me to switch layouts, and only print the current record (in a found set) and users are able to print the one record, whether they have chosen to print one or all of current records being browsed or just current record. This seems to work about 95% of the time.

3. Find Current Record.

This is where I set the curent Record ID to a global, change layout, enter find mode, set Record ID = to global, perform find and the found set is the record to be printed. Again the user can have their printer options set to whatever.

Options 2+3 gives me the same result, although option 2 is simplier but only seems to work 95% of the time.

I will spend time getting the Applescipt working, so that I can simply change layouts - without using option 2 or 3.

Can someone please corect me if I have misunderstood my options,

Thanks,

Darrin,

Posted

Is there actually a relationship between RecordID and itself? I am assuming both layouts are based on the same TO.

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