Page 1 of 1

null in headless client

PostPosted: Mon Feb 20, 2006 1:25 pm
by Harjo
I am using this in a jsp-page

Code: Select all
<td>unitprice</td><td><input type="text" name="unitprice" value="<%=servoy_hc.getDataProviderValue(null,"unitprice")%>"></td>


when the unitprice is not filled in yet, I get an annoying: null
in this field.

How can I prevent this? I want that the fields become empty, instead of showing: null

PostPosted: Mon Feb 20, 2006 1:44 pm
by IT2Be
Unlike with javascript you really have to check for a null value
Code: Select all
value != null
. By capturing the null value you can set the value/field to what you want...

PostPosted: Mon Feb 20, 2006 2:19 pm
by Harjo
Can you give me an complete example how to to this in jsp?
I can't get it to work!