[SIZE=2][COLOR=#0000ff][COLOR=teal]'this is if you want to add date in format mm/dd/yy ..otherwise remove method toShortDateString[/COLOR]
Me[SIZE=2][COLOR=#000000].TextBox1.Text = [COLOR=blue]Date[/COLOR].[/COLOR][/SIZE][/COLOR][/SIZE]Now[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#000000].ToShortDateString [/COLOR][/SIZE]
[/COLOR][/SIZE]
[SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Me[/COLOR][/SIZE][SIZE=2][COLOR=#000000].TextBox1.Text = [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff]Date[/COLOR][/SIZE][SIZE=2][COLOR=#000000].Now.AddDays(3).ToShortDateString[/COLOR]
[/SIZE][/COLOR][/SIZE]
' Set strUsername and strPassword
strTransId = txtTransactionId.Text
strDate = DateTimePicker1.Text
strMediaId = txtMediaId.Text
strPaymentType = cmbPayment.Text
'strDate = txtDate.Text
'strReturnDate = txtReturn.Text
' strReturnDate = DateTimePicker1.Text
strPrice = txtPrice.Text
Me.txtReturn.Text = Date.Now.ToShortDateString
Me.txtReturn.Text = Date.Now.AddDays(3).ToShortDateString
strTransId = txtTransactionId.Text
'strDate = DateTimePicker1.[B]Value[/B]
strMediaId = txtMediaId.Text
strPaymentType = cmbPayment.Text
strPrice = txtPrice.Text
Me.[B]txtDate[/B].Text = Date.Now.ToShortDateString
Me.txtReturn.Text = Date.Now.AddDays(3).ToShortDateString
strSQL = "INSERT INTO Transactions(Trans,Date1,MedId,Payment, ReturnDate, Pr) " & _
"VALUES ('" & strTransId & "', '" & [COLOR=blue]Me[/COLOR].[B]txtDate[/B].Text & "', '" & strMediaId & "' , " & _
"'" & strPaymentType & "' , '" & [I][COLOR=blue]Me[/COLOR].txtReturn.Text[/I] & "', '" & strPrice & "')"
Dim objCommand As New System.Data.OleDb.OleDbCommand(strSQL, objConnection)
objCommand.ExecuteNonQuery()