3 Replies Latest reply on Dec 17, 2013 4:54 AM by john.s

    Problem validating data

    john.s

      Title

      Problem validating data

      Post

           I'm very new to FM...I'm trying to prevent the input of data into a field when a different field is empty.  For example when there is no date in the PhotoRetakeDate I want to prevent the inadvertent input of a date in the ProofsSentForRetake field.  I can do it at the layout level using a script trigger  but I will run in to this in a lot of layouts and want to do it at the Field definition if possible...I can't figure out how to do it in the Validate using a calculation area.  Any help will be greatly appreciated...I'm sure this is simple just not simple enough for me yet.

           Thanks,

           John

        • 1. Re: Problem validating data
          RickWhitelaw

               It seems to me that if you implement Validation on your second filed, something like (by calculation)  If ( IsEmpty(field one);"  ") that should work. Then set things up to  ake a custom response to the Validation Error.

               i'm on an iPad at the moment so cannot test what I just wrote.

               rick.

          • 2. Re: Problem validating data
            john.s

                 Thanks Rick,

                 That is how I first thought of doing it but can't figure out how to alert the operator that the entry is not valid or allow the entry if it is valid.  If I put "  " as the first result of the if statement that doesn't alert the operator that they are in the wrong field...and what do I put in the second result of the if statement to allow the entry to go forward?

                 John

            • 3. Re: Problem validating data
              john.s

                   Hey Rick,

                   It was getting late last night and after looking at your answer and trying it again this morning I found that it does work.  The problem I have is that when I validate at the field level like this the user gets two messages in addition to the one I created.  The two from fm ask if they want to revert the record.  The question is asked twice and the users are getting confused.  Looks like to keep this clean and not confuse the users I'll have to use script triggers so I can have more control over how the system reacts.

                   Thanks again for you response,

                   John