[TEXT]
I have in Visual Basic 8.0 a MaskedTextBox1 with the mask "00/00/0000" (short date)
I have in my MYSQL table a fields :
"name" datetype CHAR(15)
"birth-date" datetype DATE
"birth-place" datetype CHAR(15)

I have one record:
Name birth-date birth-place
Andre 01-01-1974 Amsterdam
[/TEXT]

Me.TextBox1.DataBindings.Add("text", myData1, "name") 
Me.MaskedTextBox1.DataBindings.Add("Text", myData1, "birth-date") 
Me.TextBox1.DataBindings.Add("text", myData1, "birth-place") 
Labeltext1="Name" 
Labeltext2="birth-date" 
Labeltext3="birth-place"

If I run my Visual Basic 8.0 program then he show this:
Name birth-date birth-place
Andre 11-19-74_0 Amsterdam

[TEXT]
Can someone help me with this problem
[/TEXT]

Recommended Answers

All 2 Replies

Use,

Me.MaskedTextBox1.DataBindings.Add("Text", dt, "Date", True, DataSourceUpdateMode.Never, Nothing, "MM-dd-yyyy")

Use,

Me.MaskedTextBox1.DataBindings.Add("Text", dt, "Date", True, DataSourceUpdateMode.Never, Nothing, "MM-dd-yyyy")

Thanks for quick response.
This is the solution, thanks "ADATAPOST"

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.