Ok now i'm trying to Insert more then one field into my database after users input and submit a form but im receiving errors..my code reads as
string connectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Inetpub\wwwroot\DEMO1\Demographics.mdb";
OleDbConnection myConnection = new OleDbConnection( connectionString );
string query = "INSERT INTO demographics_tbl [Last_Name], [First_Name] VALUES ('" + "LastName.Text" + "FirstName.Text""')";
OleDbCommand myCommand = new OleDbCommand();
myCommand.CommandText = query;
myCommand.Connection = myConnection;
But everytime I run my form and I enter in all data and submit I get an error dealing with the myCommand.ExecuteNonQuery() function.
What am I don't wrong now? Am I missing a step. Any help would be great
Thank you in Advance.