2 Replies Latest reply on Jul 9, 2015 1:32 PM by BorisKamp

    if field is not emtpy set var and perform find

    BorisKamp

      Title

      if field is not emtpy set var and perform find

      Post

      Hi guys,

      I'm creating a script to performs finds (constrain found sets) based on values of a popup menu.

      I created this script, but I thinks there's something wrong in my if [ ] statements.

      What I want is, if the field is not emtpy, set the var and constrain the found set with the $var. The var's are working correctly, I verified it with a simpler script before.

      Thanks!

        • 1. Re: if field is not emtpy set var and perform find
          philmodjunk

          I can't see any useful detail in your script. The key info that might explain how/why your script is failing is locked inside those Constrain Found Set [Restore] Steps. You would have to open up the dialogs for all three steps before we could see the necessary details.

          I prefer to create find (and constrain or extend found set) scripts following the pattern found here: Scripted Find Examples

          This keeps all the details of the find visible as well as allowing the set field steps to do things not possible inside stored find criteria.

          One other thing that you can do is perform the script and then, immediately after, use Modify Last Find to inspect the actual criteria last used. That can sometimes show you how your script is failing.

          • 2. Re: if field is not emtpy set var and perform find
            BorisKamp

            Awesome, thanks Phil!

            followed your post to create my script steps and it works flawlessly!