Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

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

Recommended Posts

Posted (edited)

I have rewritten this code several different ways but the if statement will not recognize the value in $RefStatus.  What am I missing?

Even though the Data Viewer shows that the value of $RefStatus = 1, the statement evaluates as false.

DataViewer.png

script.png

Edited by Gerry
uploaded images
Posted

Did you debug it and when it goes to that step it skips it or does your script bail before it gets there? 

 

Your script/script step may be corrupted, too.

Have you tried playing around and saying if 1 = 1? That's usually a good test. 

Posted

When I debug it, it skips the step.  If I use a different test, no problem.

I also tried deleting the IF statement and recreating, still same result.

Posted (edited)
32 minutes ago, Gerry said:

What am I missing?

We cannot answer that, because we don't know (a) what the function vLookup() does, and (b) what are the contents of the parameters supplied to the function.

Note that it's enough for the variable to contain a trailing space in order to be not equal to 1 (assuming it's defined as text).

 

Edited by comment
Posted

Issue Resolved:  the vlookup function was causing a problem.  Vlookup was posted on the Brian Dunning site and works great with text results, but seems to have issues with numeric values.  Thanks for the feedback.

Posted

Thanks Agnes,  I passed the value as a parameter to the script and removed the vlookup function.  That resolved the issue.

  • Like 1
Posted

There are a lot of great functions on that siege. Some of them have bitten me in the behind before. So test the hell out of them before putting them in production unless it's one you've used before.

Recommend getting Clip Manager to save the ones that work for you. I have an entire library of scripts and functions that Inreuse.


Sent from my iPad using Tapatalk HD

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