Numeric Attribute / Input fields

When an Attribute's datatype is defined as an "Integer", and it is inserted into a input field, onload the attribute variable will display as "0". how do you have it display up as a blank field?

Any other way to do it besides changing the attribute datatype to text, or having to create a  text variable to hold the input value then converting it to a integer value?

Hi Robert.

In Web Input widgets you have the Null Value property in which you can specify which value should be shown as blank (for example, for a date field this value would normally be the null date vale #1900-01-01#).

Read about it in the Web Input Widget Properties in the Service Studio online help.

Best Regards,

Daniel Lourenço
Hi Daniel

Have tired this before, it does not work for blank default when the datatype is an integer

1 - insert a "Input" widget on to a webscreen
2 - assign it to a integer datatype variable

Now if you try to specify a blank value ""  it would not accept this values because it requires an integer value 
ie specifying the null default values with 1, 234, would work.

Required - Onload, all input boxes should be displayed with no values, (blank) "" (including numerical input boxes).
Hi Daniel,

I have the same problem as Robert, I want to show a blank value in the input widget if the integer variable is null, instead of showing '0'.

Do you know how could we do this?

Best Regards,

Migurl Pereira


As Daniel wrote the input property "Null Value" should be used to "hide" a given input value when the associated variable already has that value.

Usually this pattern is associated with a non required/mandatory fill of certain inputs (the not-fill means the default value, in this case the "Null Value". So the input should not be mandatory. There is also the possibility of cleaning up the input (via javascript)...

João Portela
Hi Robert and Miguel,

If you want the value 0 to be presented as blank, you have to set the Null Value property to 0. This means that when the input value holds the value 0, nothing will be shown in the input. See below how to do it.

Best Regards,

Daniel Lourenço
Hi all

You should note, however, that this will only be useful if 0 = no value in your data model. If there is no value that can intuitively be "null" in your data model, you should opt for the text variable.

Check this thread: Handling blank form fields in a world without NULLs

Thank you for your help and the tips given!

My client did not want to see the value '0' for example in an account number edit box and also in a few fields, and so it was resolved quickly with the addition of '0 'in attribute' Null Value 'of' Input Widget.

Thanks again, Best Regards,

Miguel Pereira
Hi guys,

@Miguel, great to hear that!!!

@Robert, did you solve your problem? need additional help/information?

João Portela

problem solved, thanks.