I'm totally new. I'm following a book and teaching my self C#. I'm reading one of the HEAD FIRST books. I just created a contact data base program. I made the SQL database placed it on a form did all the steps. And when I go to run the program I get this view source print?
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication1 {
public partial class Form1 : Form {
public Form1() {
InitializeComponent();
}
private void pictureBox1_Click(object sender, EventArgs e) {
MessageBox.Show("Contact List 1.0. \nWritten by: Greg Amero", "About");
}
private void peopleBindingNavigatorSaveItem_Click(object sender, EventArgs e) {
this.Validate();
this.peopleBindingSource.EndEdit();
this.tableAdapterManager.UpdateAll(this.contactDBDataSet);
}
private void Form1_Load(object sender, EventArgs e) {
// TODO: This line of code loads data into the 'contactDBDataSet.People' table. You can move, or remove it, as needed.
this.peopleTableAdapter.Fill(this.contactDBDataSet.People);
}
}
}
At the this.peopleTableAdapter.Fill(this.contactDBDataSet.People); I get an error msg saying
SqlCelnvaliddatabase format exception was unhandled.
The database file has been created by an earlier version of SQL Server Compact. Please upgrade using SqlCeEngine.Upgrade() method. I get the above error using visual 2010
If I use Visual 2012 express it works fine and I'm thinking it has something to do with the SQL Server CE versions they run off of. I've installed SQL Server CE 3.5, 4.0 , etc but still not work.. Please help..
Greg
Visual 2012 express, what version doesn't it work in? - Mike Perrenoud