0

Hello! I am currently developing a web interface that has access to an MS ACCESS database. However, I am unable to key in more than 6 Values into the database using the INSERT INTO sql code.

Here are the codes that I am using:

 protected void bnAddPart_Click(object sender, EventArgs e)
        {
            DataLayer.DataConnector dat = new DataLayer.DataConnector("Provider=Microsoft.ACE.OLEDB.12.0;Data Source='" + Server.MapPath("MainData.accdb") + "'; Persist Security Info=False;");
            int dt = dat.DataInsert("INSERT INTO tbl_addpart(partno, serialno, location, technician, status, failuresymptom) VALUES('" + ddlPartNo.SelectedValue + "', '" + txtSN.Text + "', '" + ddlLocation.SelectedValue + "', '" + ddlTechnician.SelectedValue + "', '" + ddlStatus.SelectedValue + "', '" + txtFailure.Text + "')");

            {
                Response.Redirect("Home.aspx");
            }
        }

I would like to add in more than 6 values in one click. I hope someone would be able to help me!

Thank you in advance

Iz

3
Contributors
2
Replies
12
Views
4 Years
Discussion Span
Last Post by IIM
0

You can insert more than 6 values.Can you please tell the table structure and error that you are getting on inserting more than 6 values

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.