We have an input entry for a target weight that is frequently fat fingered by operators. We are looking for a way to allow them to type in the new number but then the operator will be prompted asking if they are sure with something that shows the new and old value. Does anyone have an example of this being done? I appreciate it!!
Sorry for the late response! This was an easy one; I’m surprised nobody posted on it. Here’s how you do it:
Don’t directly bind your numeric input to a tag, the way you normally would. Instead, put a property change script on it.
if event.propertyName == "doubleValue": if system.gui.confirm("Are you sure you want to change the value to: " + str(event.newValue), "Fat-Finger Confirmation"): system.tag.write("your_tag_path", event.newValue)