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

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

Recommended Posts

Posted

I am updating an old database that I haven't used in awhile. I used to use EventScript plugin to launch a script from a calculation, but have lost it and it doesn't seem to be available anymore. Is there a built in way to accomplish this now?

My calculation is just an if statement that checks if there is an entry in a related table, and if not, launches a script.

Thanks

Posted

Thanks for the suggestion. That seemed like it would work, but I'm having a hard time writing the if statement to check to see if there is an entry on the related table based on what was just entered into my field (a barcode number).

Was trying

 If ( not IsEmpty ( BtlBarcode ) and LiquorCatalog::Barcode = ""

but it launches the script whether there is a matching entry or not.

Posted

It may be to do with the brackets and comparing to an empty string.

Does If ( not ( IsEmpty ( BtlBarcode ) ) and ( IsEmpty ( LiquorCatalog::Barcode) )

work better?

Posted

I could help more if I knew what your script did. Looks like a simple scenario where the user scans a barcode and that is captured in a global field. The script would simply do a find for that barcode. What are you doing?

bwt, yes, script triggers always run. This one might be onObjectExit (given the scanner enters a trailing return or tab). Then, the script called by the trigger would validate that the barcode isn't empty (if so exit) or proceed with a find.

Posted
On 11/19/2017 at 11:24 PM, rwoods said:

It may be to do with the brackets and comparing to an empty string.

Does If ( not ( IsEmpty ( BtlBarcode ) ) and ( IsEmpty ( LiquorCatalog::Barcode) )

work better?

That seems to have done the trick!! thanks for the suggestion.

Will not know for sure until this Sunday when I will be using the database again, but for now, it seems like it's working.

Thanks again.

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