Hi,
I have a winform which contains three comboboxes to have a date of birth of a person in the form mm dd yyyy. Now i want to know how should i declare variables in the form inorder to have these values selected and then inserting into mysql db. In mysql i have declared this attribute as
dateofbirth datetime not null
now in the form what i have to write in a insert query
Niradhip ChakrabortyPosted Apr 3, 2009, 8:52 AM
You can directly give the combobox value in your insert statement. 'OnHoldCreditCard' is the name of the table and
'cboExpireYear' name of the combobox.
strSQL = "INSERT INTO OnHoldCreditCard (ohc_dtm_CreditCardExpYear) values ('" + cboExpireYear.SelectedItem.Text + "')