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

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

Recommended Posts

Posted

This has been driving me nuts for years. I just did some troubleshooting and found that it's only a FileMaker problem, other programs are not affected, so I thought I'd ask here...

If you print a page in FileMaker, then change the printer (applescript or manual), then print another page in FileMaker, the print dialog will still show the original printer unless you execute the second print AFTER the first job has FINISHED printing.

I always thought it was an Apple problem, but strangely enough, this problem doesn't happen in other apps.

It DOES work if you print something with another program, then change printers, then print something within FileMaker while the original print job is still running, suggesting to me that FileMaker somehow attaches itself to its own print jobs, unwilling to default to the default printer until its jobs are completed.

Does anybody have any insight or workaround? Anybody NOT have this problem?

Posted

It is possible to get the name and busy status of the current printer by applecript and wait until the printer is done.

Posted

Do you have something that I can look at? I have been trying to change printers in FM 7 running on Mac OS X for awhile with no success. I can change the printer either in the Print Setup or an Applescript but when I perform the Print script step, it still has the previously used printer. Any idea's?B)

Posted

tell application "Printer Setup Utility"

name of every printer

choose from list result

set selectedPrinter to result as text

set myFlag to 1

set current printer to printer selectedPrinter

repeat 10 times

if name of current printer = selectedPrinter then

set myFlag to 0

exit repeat

end if

delay 1

end repeat

if myFlag = 1 then display dialog "Well this didn't work. Your printers are very busy and you should come back some othet time."

end tell

  • 4 months later...
Posted

Still no luck. Although the above will change the default printer in Printer Setup Utlility, FM7 will still print to the last printer used with the print script step is set for no dialogue. Any suggestions?

  • 1 month later...
Posted

Getting a little closer on this one. Turns out the only way to make FMP see the printer changed in Printer Setup Utilility is to use call a print comand, have the GUI manager to cancel a print command, then print again. Now I just have to learn how to use the GUI manager, uggh.

  • 2 weeks later...
Posted

You must be leaving something out. The script supplied above works fine and WILL print to the changed printer reliably every time without extra trickery.

Posted

Hi Doug,

I agree with you 100%. I've been trying to control FMP with the GUI manager. No luck yet... Any idea what I've done wrong?

tell application "FileMaker Developer"

activate

end tell

tell application "System Events"

tell application process "FileMaker Developer"

click the menu item "Print

Posted

tell application process "FileMaker Developer"

should be

tell application process "FileMaker"

I don't know why, but is must be. Actually kind of nice in that the process is the same for FMD and FMP.

Check out the attached example.

Cheers

DJK

Posted

Of course it doesn't work. You are commanding it not to work.

You choose a new printer with applescript and then immediately discard the result. You print with "restore printer" turned on. Turn it OFF.

PrintProb.zip

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