Jump to content
docasar

Script on debugging works, but not when running

Recommended Posts

Hello,

I am still very amateur on Filemaker so i hope my question does make any sense.

I am trying to write a script that would basically import order information from an email and convert it, first in a new account (if the customer does not exist) and later create a Sale Order. So far, I have managed to do that, but the problem i find is when trying to convert the sale order into an invoice. Since this order comes from our webshop when we receive the email means it is paid, so my aim is that when creating the invoice from the Sale order, this would be marked as paid and set the amount due to zero.

This would sound a very easy task, but since our solution incorporates a payments module to manage the payment of an invoice, when i try to incorporate the payment entry within my script, there is when all the trouble starts. For some reason, it gets lost in its way when runnig the script and returns a partial payment all the time. The weirdest thing is thet if I run the script on debug mode, then all works perfectly, so my guess is that the issue may be related to the speed of the script.

So, is there any recomendation as for where to put a pause script step so the script will work also when run automatically?

I have tried every possible combination of long script, shorter with other scripts inside, perform script on server... and all the time something is wrong ;(

Thanks a lot for any insight thst would help us move forward, since we have been trying to solve this for a week already.

 Best

Luis

Share this post


Link to post
Share on other sites

Can you post the script or a clone of the file? 

Share this post


Link to post
Share on other sites

Hi docasar

or

Save a copy as »» clone  "no records of the file.

 save file as a Clone.png

Share this post


Link to post
Share on other sites

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


×

Important Information

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