I change my code like this, now it works fine but I have small problem.
if my dropdowns SelectedIndex==0 then I wants to insert null value. I used for DBNull.Value, but it save as "01/01/1900" but I want to insert "<Null>" How can I do this?
I change my code like this, now it works fine but I have small problem.
if my dropdowns SelectedIndex==0 then I wants to insert null value. I used for DBNull.Value, but it save as "01/01/1900" but I want to insert "<Null>" How can I do this?
there is no simple way that you can insert a null value into sql database from .net, the ony want you can do is, to use parameter, and then declare it as SqlDbType.DateTime, and then insert an empty SqlDateTime variable in to it..
Bookmarks