Posted on: 8/2/2013 6:33:37 PM | Views : 247

Hi there,
            Am beginner :) how can I insert a string into a table?
1. Having 2 text boxes, a Button and a checkbox.
2. Having sql table name 'sample'
if the check box is not selected, the two text box values can be added into table as follows
insert into sample values('" + TextBox1.Text + "','" + TextBox2.Text + "')
My question is, how simply i can set the second text box value to be "default" ,if the checkbox is selected
      insert into sample values('" + TextBox1.Text + "','" + "default" + "').   Is this correct?

Thanks in advance...
Go to the complete details ...