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

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

Recommended Posts

Posted (edited)

I am trying to validate a variable in a script I created. I want the script to skip over the variable to an else statement if the variable is not valid but neither the if(NotValid) or if(IsEmpty) script steps are getting me the result I want.

Is there something else I need to know about validating with variables?

Edited by Guest
Posted

Let's say you set $var = 1.

Then:

If [ not isempty ( $var) ]

do this stuff

else

do other stuff

endif

should work. In fact, you could probably just say if ($var).

Posted (edited)

Unfortunately I can't simply match the variable name because it is dependent upon the logged in users username. For some reason the if [not isempty ($var) ] still doesn't work correctly, but I came up with Case (not(IsEmpty($$path));True;False) = "0" that returns a 1 and 0 when the variable is present and not present and this seems to get the job done.

Edited by Guest

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