K
Kevin
Hi All
I have a DateTime object called dt. the format of dt.Date
is mm/dd/yyyy. How can I change this format to dd/mm/yyyy
and still keep it as a DateTime object so that I can run
this following SQL query :
UPDATE WorkRoster SET DateWorking = ? WHERE DateWorking IS
NULL
I have added a parameter to hold the date.
I have tried to make my parameter = dt.ToString("d"), but
when the Update statment runs I get and OLEDbException
that is thrown, telling me that the Paramter does not have
a default value. I assuming it's maybe telling me this
because I tried to enter a string in the parameter?
The database is an Access 2000 DB and the field's datatype
is ShortDate.
How can I solve this problem?
Any help is much appreciated
TIA
Kevin
I have a DateTime object called dt. the format of dt.Date
is mm/dd/yyyy. How can I change this format to dd/mm/yyyy
and still keep it as a DateTime object so that I can run
this following SQL query :
UPDATE WorkRoster SET DateWorking = ? WHERE DateWorking IS
NULL
I have added a parameter to hold the date.
I have tried to make my parameter = dt.ToString("d"), but
when the Update statment runs I get and OLEDbException
that is thrown, telling me that the Paramter does not have
a default value. I assuming it's maybe telling me this
because I tried to enter a string in the parameter?
The database is an Access 2000 DB and the field's datatype
is ShortDate.
How can I solve this problem?
Any help is much appreciated
TIA
Kevin