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

printing script only works part of the time


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

Recommended Posts

Posted

I have a printing script that I wrote that only works part of the time. Basically, whenever I open the file and print one of the records, it prints fine. If i hit print again on that record or any other record it only prints the FIRST record. If i quit out of the program and go back in, then it will do the same thing (print correctly and then not print correctly). I am using OSX.2 and FM6. Here is the script which is place on a button for the current record:

Set Field ["gID", "Status(CurrentRecordNumber)"]

Allow User Abort [Off]

Omit Record

Show Omitted

Go to layout ["Print"]

Enter Preview Mode []

Page Setup [Restore]

Print[]

Enter Browse Mode[]

Go to Layout [Original Layout]

Go to Record/Request/Page ["gID"]

Show All Records

Perform Script [sub-scripts, "Screensize"]

Any suggestions? Also, FM only returns to the current record on the first print every other print it goes to the first record.

Thanks,

Shana

Posted

Status(CurrentRecordNumber) gives the record number in relation to the current found set. You are changing your found set with the omit, show omitted steps.

If I'm reading what you want to do correctly, try:-

Allow User Abort [Off]

Show all records

Omit Record

Show Omitted

Go to layout ["Print"]

Page Setup [Restore]

Print[]

Go to Layout [Original Layout]

Perform Script [sub-scripts, "Screensize"]

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