Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

I have been trying to do this script that will print a document for a record but it will not work correctly.

What I want it to do:

User on a data entry layout in browse mode, clicks print button. Window stays on this layout (from users view point) and a print dialog pops up. They choose the stuff in print dialog and click print. Document prints. During this entire process the user should never see any other layout on screen except the data entry and the print dialog.

What script really does:

When the user clicks the print button on data entry screen, the layout that is being printed, is displayed in preview mode in the window while the print dialog is shown. Once the the print dialog is gone then it jumps back to the data entry layout in browse mode. I don't want this to happen.

Script steps:

Set Error Capture [On]

Freeze Window

Go to Layout ["Layout to be printed"]

Enter Preview Mode []

Print []

Enter Browse Mode []

Go to Layout [original layout]

My thoughts:

Two things maybe happening here:

1. I am not doing this correctly, FM 7 does freeze windows for printouts differently than FM 6 and below.

2. This may be a bug in FM 7. frown.gif

Any thought from others is welcomed.

Posted

Yes I have seen this behaviour too. I'm on Mac OS X, but I haven't tested it on Windows.

It is most probably a bug. I'm sure FMI knows about it already.

Posted

I too had this of a problem and the only workaround solution that I have done and seen others have done is create a new window and have that window positions somewhere out of the user's screen realstate. The new window will have the print layout and print command execute on it.

Do however make sure that when they have completed the print or canceled the operation that you close the window immmediately since you don't want a window floating out where the user can't close it.

Hope this is of help...

Thanks.

Posted

I too had this of a problem and the only workaround solution that I have done and seen others have done is create a new window and have that window positions somewhere out of the user's screen realstate. The new window will have the print layout and print command execute on it.

Do however make sure that when they have completed the print or canceled the operation that you close the window immmediately since you don't want a window floating out where the user can't close it.

This seems like a good work around.

Thanks

  • Newbies
Posted

Change your script:

Script steps:

Set Error Capture [On]

Freeze Window

Go to Layout ["Layout to be printed"]

Enter Preview Mode []

Print []

Enter Browse Mode []

Go to Layout [original layout]

to

Script steps:

Set Error Capture [On]

Freeze Window

Go to Layout ["Layout to be printed"]

Print []

Go to Layout [original layout]

For printing you don't have to enter Preview Mode.

And when you say "Enter Preview Mode" what else should FM do than to prieview?

Posted

Change your script:

Script steps:

Set Error Capture [On]

Freeze Window

Go to Layout ["Layout to be printed"]

Enter Preview Mode []

Print []

Enter Browse Mode []

Go to Layout [original layout]

to

Script steps:

Set Error Capture [On]

Freeze Window

Go to Layout ["Layout to be printed"]

Print []

Go to Layout [original layout]

For printing you don't have to enter Preview Mode.

And when you say "Enter Preview Mode" what else should FM do than to prieview?

I thought whenever you print any layout that may print multiple pages must be in preview mode first before printing.

Examples:

Invoices

Labels

reports

etc

I don't see how filemaker would know when to print one record or multiple ones on a single page without the preview mode step. Now I am confused.

Posted

You need to add a "Print Setup[Resore,No Dialog]" script step before the Print[] step. This step is where you define whether FileMaker prints the current record or all records in the found set.

and no, you don't need a "Enter Preview Mode" step to print.

Posted

Actually, in 7, you don't need the Print Setup step for 'current record', etc., as the Print settings can be specified and stored within the Print step. You do need it, however, to specify the Portrait/Landscape details.

Posted

For printing you don't have to enter Preview Mode.

And when you say "Enter Preview Mode" what else should FM do than to prieview?

I tried this and the window still did not freeze. My printout layout still popped up during the print dialog part.

and no, you don't need a "Enter Preview Mode" step to print.

I tried printing some different report layouts without entering Preview mode before the print script. None of them came out the correct way. None of the slide printing objects worked. So I did some searching in FM help section and I found this.

Some items

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