title: Syntax error in INSERT INTO Statement in vb.net
body: <p>I am getting and syntax error in insert into statement. <code>IF</code> statement is working just fine just getting this error when it's trying to save the information</p>
  
  <pre><code>Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
          If txt12Per.Text &gt;= TextBox12.Text And txtGPer.Text &gt;= TextBox11.Text And TextBox1.Text &gt;= TextBox10.Text Then
              Try
                  'Dim da As OleDb.OleDbDataAdapter
                  Dim dbprovider As String = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Users\Taher\Documents\Visual Studio 2010\Projects\WindowsApplication1\WindowsApplication1\Database1.accdb;Persist Security Info=False;"
                  Me.con = New OleDb.OleDbConnection()
                  con.ConnectionString = dbprovider
                  con.Open()
  
                  Dim sqlquery As String = "INSERT INTO MCAscheduled (URno,SName,hsc,gper,pgper,pstatus,cname,hrname,position,hscinter,ginter,pginter,comments)" + "VALUES (" &amp; CInt(txtUrn.Text) &amp; ",'" &amp; txtName.Text &amp; "'," &amp; CInt(txt12Per.Text) &amp; "," &amp; CInt(txtGPer.Text) &amp; "," &amp; CInt(TextBox1.Text) &amp; ",'" &amp; ComboBox2.Text &amp; "','" &amp; TextBox3.Text &amp; "','" &amp; TextBox4.Text &amp; "','" &amp; ComboBox4.Text &amp; "'," &amp; CInt(TextBox12.Text) &amp; "," &amp; CInt(TextBox11.Text) &amp; "," &amp; CInt(TextBox10.Text) &amp; ",'" &amp; TextBox9.Text &amp; "');"
                  Dim sqlcommand As New OleDb.OleDbCommand(sqlquery)
  
                  With sqlcommand
                      .CommandText = sqlquery
                      .Connection = con
                      .ExecuteNonQuery()
                      con.Close()
                      txtUrn.Text = ""
                      txt12Per.Text = ""
                      txtGPer.Text = ""
                      txtName.Text = ""
                      cmbNameofGCourse.Text = ""
                  End With
                  MsgBox("Record Added")
              Catch ex As Exception
                  MsgBox(ex.ToString)
              End Try
          Else
              MsgBox("Student Not eligible for the requested company")
          End If
      End Sub
  </code></pre>
  
  <p>Can somebody help me with this....</p>