Click here to Skip to main content
15,914,419 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I am using DATE data type in a database table and trying to use that in VB.net front end.
How we can Convert text box content from string to date?
Posted
Updated 2-Dec-12 7:01am
v2

1 solution

Hi,

Convert textBox1.Text to a DateTime:
VB
Dim dateToInsertInDatabase As DateTime = Convert.ToDateTime(textBox1.Text)


Then, you can insert the DateTime into your database:
http://social.msdn.microsoft.com/Forums/uk/vbgeneral/thread/d11ed406-d9bf-4363-84b6-99f4e9ee4631[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900