Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Not able to add SQL Server Compact 4.0 table to dataset

Posted on 2011-10-01
4
Medium Priority
?
1,370 Views
Last Modified: 2013-11-17
I have a vb.net project in Visual Studio 2010 SP1 that uses SQL server compact 4.0 database. I recently upgraded the database from SQL server compact 3.5 to version 4.0. I changed the target framework to 4.0 in the project properties. Now when I try to drag a table from the database in Server Explorer to the dataset I get the following error:

 "The version of Microsoft SQL Server Compact database that you selected is not supported by the current project. The database and the connection will not be added to the project.".

Other than this the project builds okay and I can run it, but I can't add a table to the dataset.

Also, if I try to add a new Datasource SQL Server Compact 4.0 is not an option in the Data Source list, and in the Data Provider dropdown box the only option is ">NET Framework Data Provider for Microsoft SQL SErver Compact 3.5". There is no option for version 4.0.

Any help would be very much appreciated. Thanks!
0
Comment
Question by:myester
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 60

Expert Comment

by:Kevin Cross
ID: 36898375
HI. I just had the same experience with version 4. I believe what ultimately fixed it for me was that SP1 for VS2010 had to be reinstalled/repaired. Try that and post back.
0
 

Accepted Solution

by:
myester earned 0 total points
ID: 36902444
HI, from what I've been able to learn version 4 is not compatible with Winforms in Visual Studio. It only works with web projects.What type of project are you working with? Thanks!
0
 

Author Closing Comment

by:myester
ID: 36972661
SQL Compact Database 4.0 is not compatible with Winforms. It works with web projects.
0
 
LVL 60

Expert Comment

by:Kevin Cross
ID: 36944789
Sorry I did not get a notification on your response. I was trying this in a general Library project as I wanted to use with both a WinForm and Web Application, so the DAL was common.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question