>>How can I get the data type of a field in an ADO recordset when the value is currently Null?
>>
>>I need to set field values to a default empty string or 0, etc., for Null values.
>
>
>Dim ltype
>ltype = oRS.Fields("address").Type
>
>Select Case ltype
>
> Case adChar, adVarChar ...
>
> oRS.Fields("address").Value = ""
>
> Case adSingle, adDouble ...
>
> oRS.Fields("address").Value = 0
>
> 'etc
>
>End Select
>
Oh yeah, a lot simpler than OpenSchema!!!
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com