1,105,332 Community Members

Store DateTimePicker value to sql serve

Member Avatar
Posting Whiz in Training
236 posts since Oct 2009
Reputation Points: 0 [?]
Q&As Helped to Solve: 2 [?]
Skill Endorsements: 0 [?]

Dear Experts

I have applied following custom Format to DateTimePicker


So now DateTimePicker is displaying data as


Sql server 2005, table1 has column named Date with datetime type

How to store DateTimePicker text into date column of Table1

I want to save only date not time as 15-01-2010

Please help

Member Avatar
Posting Pro
531 posts since Mar 2009
Reputation Points: 15 [?]
Q&As Helped to Solve: 39 [?]
Skill Endorsements: 0 [?]

when i do this, my database columns for date use the YYYY-MM-DD format.
you can make yours whatever you like

INSERT INTO table_name ( DATE ) VALUES ( " & vb6.format$(now() "YYYYMMDD") & " )

hope that helps

This article has been dead for over three months: Start a new discussion instead
Start New Discussion
Tags Related to this Article