-
Hello!
I'm developing a database related program and when a field that I wanna retrieve from DB is empty, it returns error 94 (Invalid use of null).
How can I avoid this error and retrieve data from database? Is it enough to write this statement before loading data from database:
Code:
On Error Resume Next
Zvonko
-
If for example you were retrieving a field called Employee into a text box called txtEmployee then ...
Code:
txtEmployee.Text = "" & rs!Employee
The "" would stop any error due to Employee being empty.
-
or you can
try
Code:
if NOT (rs!Employee) then txtEmployee.text = rs!Employee
-
sowwy about last one
Code:
if NOT ISNULL(rs!Employee) then txtEmployee.text = rs!Employee