A1VBCode Forums
Home
»
Classic Visual Basic (VB 6 or earlier)
»
Database Programming
visual basic.net
http://www.a1vbcode.com/vbforums/Topic28825.aspx
By tawfiiq
-
2/3/2010
hi dear
i am new to vb.net , and i want to add date and time (DateTimePicker1) to my form
then when i save the record a wrong date is saved to the table , my database is sql 2005
Code: " & Format(DateTimePicker1.Value, "dd/mm/yy") & ") "
Result: 1/1/1900 12:00:00 AM
i much liked to help.............
By Mark
-
11/11/2010
how about
Convert
.ToDateTime(DateTimePicker1.Value)
EDIT: Never mind...I just noticed the date.