list box in data grid view

Aug 6 2010 4:17 AM
hello sir ;

i am using insert querry . In this querry the error occur in listBox_selected_services.Text and listBox_lab_charges.Text . i am using c-sharp express edition for front end and sql 2000 for back end . what is the error syntax of  listBox_selected_services.Text and listBox_lab_charges.Text .

the querry is :

private void button_ADD_Click(object sender, EventArgs e)
        {
            MY_SQL_NEW_QUR.Access("insert into laboratory([laboratoryrecieptid],[patientid],[patientname],[doctorname],[departmentname],[laboratoryselectedservices],[laboratorycharges],[totalcharges])values('"+textBox_laboratory_reciept_id.Text+"','"+textBox_patient_id.Text+"','"+textBox_patient_name.Text+"','"+textBox_doctor_name.Text+"','"+textBox_department_name.Text+"',"+listBox_selected_services.Text+", "+listBox_lab_charges.Text+",'"+textBox_total_charges.Text+"')",connection.My_Get());
            SHOW_MY_TABLE();
        }

Answers (1)