You can't.
In 2.0 you'll have nullable types which will make this possible.
if you need to know 'cuz you are assigning a value to a parameter for a
query, you do:
command.Parameters.Add("@SomeName", SqlDbType.Int)
if (something is null)
command.Parameters(@SomeName).Value = DBNull.Value
else
command.Parameters(@SomeName).Value = whatever
end if
Karl
--
MY ASP.Net tutorials
http://www.openmymind.net/ - New and Improved (yes, the popup is annoying)
http://www.openmymind.net/faq.aspx - unofficial newsgroup FAQ (more to
come!)
"ypul" <yp**@hotmail.com> wrote in message
news:uF****************@TK2MSFTNGP10.phx.gbl...
How can I assign dbnull.value to and integer variable in asp.net?
Private Active As Integer
my code checks for 3 values of "Active" Variable (null,0,1)