You could add vbnullstring to the end of the value and you whould not get
null
Desmond.
> hi everybody,
> I am a beginner in VB programming and i have a task to convert an
> application from DAO 3.6 to ADO 2.5
> This VB application connects to an Access 2000 database
> After going through hell and back to understand both DAO and ADO and
> resolving errors , i have a unexpected behaviour of VB 6.00 when leaving
> some fields in a modified record empty (i.e. NULL) it crashes aven
though
> the specified field(s) in question has the proprety AllowNull set to true
> The error number is ?2147217887 and the error message is more or less
like
> the following (Translated from french) :
> "The field is too small to accept the quantity of data you are trying to
> insert... try inserting less data.."
> When i tried to test for Null values :
> if field <> null then
> do desired action
> end if
> it works but i don't want to do this since i have several thousands
lignes
> of code.
> Any ideas? Thanks A LOT in advance
>
> Best regards
> Paris 11 MAY 2001