Main Site Documentation

VS 2010 Express & SQL 2008 R2 Express -- can't EF Model?


#1

In a fun project at home using C# I am trying to create an Entity Model for a DB I setup in my Express SQL.

  1. I try to “Add Data Source” from the Data Sources
  2. Select Database from the Choose Data Source Type window
  3. Select Entity Data Model from the Choose Model window.
  4. Select Generate From Database
  5. Click “New Connection …” button
  6. The Connection Property window has “Microsoft SQL Server Database File (SqlClient)” as the Data source

This data source attaches to an MDF, which isn’t what I wanted.

There’s a button to change, but it’s disabled. I’ve rebooted since installing SQL Express.

Any ideas on how to enable it so that I can connect to the SQL server?

Thanks


#2

Hi,

I’m not sure is the best forum for general development question.

Try to post your question to StackOverflow is (I think) a best way to have a answer :slight_smile:


#3

I figured I’d ask my friends first before going to strangers :smiley:


#4

If you still need help you can just use a SqlDataAccessAdapter point to your SQL Server and receive a datatable with your results…

Example:
http://www.dotnetperls.com/sqldataadapter

Connectionstring:
http://www.connectionstrings.com/