Default value for TextBox input


I need to set the default value for a Input field which called "Year". I always need to show current Year when the page is loaded.

Below is my setting,

However it does not works.

Can anyone advise?

Rank: #268

Have you tried setting the default value on the variable attached to the input box?

Hi John,

I do set the default value to the variable which attached to the input box.

However the value does not reflected on the screen

Rank: #268

A bit more detail about the variable and how your using it may help. Possibly the "Default" is being overridden by an assign. Try assigning a specific value to the variable and see if it shows.

Rank: #268

I just did a test for good measure. Create a variable, give it a default value, assign variable to an input box, publish and display page. The input box shows the default value fine. I suspect either you have linked the wrong variable, the values are being overridden or you have used the Null Value field which will "hide" the value if the variable is the same as the null value.