Dynamic Form Rules - when record is saved - requires field exit

  • 0
  • 1
  • Question
  • Updated 1 year ago
  • Answered
I am trying to check a field upon saving the form: if Field X <> 100% then show a message and abort the save.  The dynamic form rule "when the record is saved (after checking)" does not recognize the changes made in Field X if the user clicks Save before exiting the field.  The form rule recognizes the previous value, even though the record saves with the new value.  Is there any way to safeguard against this?  I want to prevent my users from saving inaccurate data, but I can only abort the save based on the field value if they exit the field first so the form rule can recognize it.  Anybody have any ideas?  Thanks.
Photo of Richard Pfister

Richard Pfister

  • 554 Points 500 badge 2x thumb

Posted 1 year ago

  • 0
  • 1
Photo of John Thomas

John Thomas

  • 1,062 Points 1k badge 2x thumb
When the record is saved
and all of the following conditions are true
Percentage is not equal to  100

Action
abort the save "Not 100 Change to 100"
change percentage to empty // Records which having already values.

i hope this will solve your issue !!
Photo of Richard Pfister

Richard Pfister

  • 554 Points 500 badge 2x thumb
Thanks for the reply John!  This triggered perfectly...once.  If I click Save a second time without changing anything it goes right ahead and saves it.  Upon closer examination, the "change percentage to empty" is not happening on the form.  I tested it with "Fire change options only when something changes" both checked and unchecked.  I tested it with changing the percentage to empty and to "0".  It always triggers the first time (without exiting the cell), which it didn't before, but it isn't doing it a subsequent time and I have to believe I'm doing something wrong with the change action because I don't see it changing.  Any thoughts?

Here's my rule:
When the record is saved after checking
and percentage is not equal to 100
abort the Save "Not 100 Change to 100"
change percentage to 0
Photo of Matthew Neil

Matthew Neil

  • 31,478 Points 20k badge 2x thumb
percent fields are not 100, but rather 1 displayed as 100%.  Try adjusting the rule to be <> 1
Photo of Richard Pfister

Richard Pfister

  • 554 Points 500 badge 2x thumb
Thanks for the suggestion Matthew.  I tried it but no change.  I'm testing with a value of 90, which is neither 1 nor 100, so it should trigger no matter what, and it still does initially, but not subsequently.
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 53,842 Points 50k badge 2x thumb
I have seen bugginess with another forum poster trying to trigger on percentage field sand suggested that the go to QuickBase support.

On idea to try is to make a formula field of the percentage field times 100 and set it to be a plain numeric formula field (not a percentage) and see if that works.
Photo of Richard Pfister

Richard Pfister

  • 554 Points 500 badge 2x thumb
I tried this approach but no change.  I try not to bother the support team with my n00b questions but since the rule triggers correctly once and not again I agree it may be time to open a ticket.  Thanks.
Photo of Richard Pfister

Richard Pfister

  • 554 Points 500 badge 2x thumb
The answer turned out to be that I needed "when the record is saved"...without the "(after checking)".  I'm not sure that I understand why this change fixed it but it works perfectly now.