Numeric Text Field Out of Bounds Message

in Ignition 8.1.31, when typing a value outside bounds, how can I customize my out of bounds message to inform the user that max value is for example 6000 (driven from a a tag in the PLC)?
Thanks

Perspective or vision ?

in vision.
thanks

I added the tag and moved the whole thing to the ignition category.

Make sure to include the relevant tags next time, it makes things easier for those who can help you.

Great. Thank you.

There are a lot of ways to go about this. Could you be more specific about what are you envisioning? Examples: a warning label, auto correction, preventing tag writes for out of bounds values...

Well, usually when you have a numeric entry and already specified in its property editor the minimum and the maximum value i.e. 0 - 100. when I click on the box in run time and pop numeric entry dialog-box appears for users to enter their range, they have no idea what the range is, other systems would send the min & max values to be displayed in the popup numeric entry as a reference.

I understand I can have many ways of doing this, I could possibly add a label next to the field indicating the allowed range but with a very busy display, this is the last thing I want to do...

I thought there was a default (built-in) way of passing these values to the numeric popup dialog entry.
Thanks

How is this popup being shown?

As long as Use Bounds? and Error on Out-of-Bounds are true, then you can input whatever you want into the Out of Bounds Message

image

1 Like

I used scripting and mouseover text event to control this...Thank you

1 Like

I was contemplating an underlay for this.

On the numeric text field, set the background to a transparent color, and bind the foreground to the background (so the numeric text is always initially invisible)

Then underlay a right aligned text field with a nice light grey text. Put a binding on its text property to display the range at initialization:

'(' + {TestWindow.Numeric Text Field.minimum} + ' to ' + {TestWindow.Numeric Text Field.maximum} + ')'

Finally, put a script on the numeric text field's `focusGained event handler to blow away the pretext and restore the numeric text field's foreground color when it's time to enter a value:

event.source.parent.getComponent('Text Field').text = ''
event.source.foreground = system.gui.color('black')

Result at window open:
image

Result on user selection:
image

...and of course, continue using these behavior settings to keep the values in bounds without having an offensive message popup:
image

Edit: I should note that custom components configurations that are going to be used in more than one place should be templatized to reduce potential maintenance costs down the road.

1 Like