Jump to content

Script works with pause, not without...


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

Recommended Posts

I have a script that jumps around to several layouts doing searches and then replacing a value based on the result of the searches. Now when I don't put pauses into the script at certain points the value doesn't get changed. When I put the pauses in it does change. Why would this be? I haven't changed any of the script at all besides adding pauses. Is it possible that the script is getting ahead of itself for some reason and isn't running properly? I jump to three seperate layouts and do two searches before replacing a value on the last layout....

Link to comment
Share on other sites

When I put the pauses in it does change. Why would this be?

The diagnosis "Ahead of itself" is far fetched ...instead has it to do with when a record is committed.

Try to replace the pause with a "Commit Record" ...and see if get the desired behaviour? But since you're on FM8 should you utilize GetNthRecord as well as relations for such task and you'll find your lengthy and perhaps cluncky scripts gets shortened considerably.

Filemaker doesn't lean against the event model other RDBMS subscripe to, native filemaker doesn't have event triggers but provide a unique class of tools called calculationfields similar to spreadsheets dito.

So what you might have learned in your formal education doesn't fit exactly ...it's important to adabt to this way of thinking, instead of making french fries with a tennisracket - metaphorical speaking for the issue of picking the right tool for the job at hand.

A not neglectable number of questions here are from people trying to make filemaker into what they at first hand assumes is the method to accomplish things.

--sd

Link to comment
Share on other sites

GetnthRecord? Hmmm I will have to try that out. Yeah filemaker is definitely not the standard I am used it. Going from Oracle 9i, MySQL, and Access to Filemaker and 4th Dimension on the MAC is a big change.

That GetnthRecord isn't a script step is it? I can't seem to find it. Or should I be using goto record/request/page to do searches instead of find all the time? I can still use Get(LastError) = 401 to catch it if it isn't there with goto right?

Edited by Guest
Link to comment
Share on other sites

Mac modality, which these days can seem a little oldfashion - demands a button or a remapped shortcut to allow such action, otherwise must you seek shelter under an event trigger plugin.

Alternatively can you make the entry the user makes primary key for filling a portal with maching stuff ...well CF's (custom functions) might also via thier ability to make recursive calls be able to locate an ID or a set of ID's matching your requests, again utilizing GetNthRecord(

I would suggest that you use the modality approach as well. A very well designed example of this is this template:

http://www.nightwing.com.au/FileMaker/demos8/demo804.html

Try to see if yo can get the gist of it!

--sd

Link to comment
Share on other sites

This topic is 5729 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
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.