GridView w/ ObjectDataSource change null integer into zeros

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I currently have a custom GridView control bound to a ObjectDataSource
(business objects)

When calling the "ObjectDataSourceView.insert(...)" and
"ObjectDataSourceView.update(...)", EMPTY grid fields corresponding to
INTEGERS are saved as 0 (ZERO) instead of nothing!

for instance, I have a business object "StandardDetail" with a
"standardNumber" member of type Integer; when loaded from the dataBase (very
first time) records with no values are displayed as empty fields in the
gridView, after I update one of these records (leaving the field blank) the
value becomes ZERO.

I tried converting the member type to Nullable(Of Integer) but "Nothing" is
then not accepted anymore (as opposed to being transformed n 0).

Does someone have any idea on resolving this issue?

Thanks,

R.
 
Rachel,

As that are the business rules in the Busines Object that you have got, than
we cannot change anything in that.

It looks for me that it get initial null/nothing and that it returns a empty
string if it is a null value.

Just my thought,

Cor
 
Back
Top