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

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

Recommended Posts

Posted

Hi everyone - merry christmas!!

1. If I had office hours of 8pm-8pm, and I needed to print out a report for the office hours business in those times, then I think I have the solution. Check if I'm wrong please.

I create a field that contains a number that goes up +1 at 8pm every day and I do a search of all records based on the number I've got which would be everything with that number up until 7:59pm when it was updated +1.

But, I need to know how to get the Filemaker Server, which holds all Sales in a lineage format, to process a script at 8pm which #1 Prints out all current sales with today's number and then incriments +1 for all sales there after to look up. I also need to know what type of field to use to store the number that I generate which is universally accessable for a lookup without it being a field that is modifiable per record. Is it a Global Field I need?

Mr Bob Weaver, I thank you for your Applescripts that you created for the purpose of Printer Tray selection and Printer selection. I'm dreading trying to use them since I don't really know how to use Applescript! Happy Christmas!

Posted

FM Server cannot process scripts. You'll have to make sure that you have the database opened in a client each evening.

Posted

There is a way to do what you’re wanting to do on the server. It does require the file to be closed on the server while this is done, but it doesn’t require any plug-ins – just FileMaker software.

1. You need a client FileMaker version installed on the server – with NO network protocol selected.

2. The file(s) you want the print routine to be run on should be set as single-user when not hosted by FMS. This will not affect FMS hosting of the files.

3. Create the script in the file with your finds, sorts, and print routines.

4. Create a standalone FM file that has one script to call the external script created above (3). The last step in the script must be to exit application. Set this script to run when the file is opened. The file should be saved in the same folder as FM server, but not opened or hosted by FMS.

5. There are some applescript files in the Examples folder that deal with the old “Today” function. One calls FM Server to close the file, one calls the file to be open by the client software, and another to reopen the file on FM server. These applescripts can be easily modified to close the hosted file, then open the file created in (4) with the client version – which will call the script to run and print your reports, then call FM server to then reopen the file.

6. Set FM server Scheduler to run these applescripts at a set time – maybe right after 8 PM. Just make sure there is plenty of time between running the 3 applescripts for the tasks to complete before starting the next applescript or the scripts won’t run right.

We use this scheme to presort some large databases to facilitate quicker opening for users. The routines run at night as part of our backup routine. We use this for both our Mac FM servers using Applescript and on NT FM servers using CMD (.bat files work too) files.

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