1

Just started using VS 2012 and I generated an EF Model from the database. All worked fine, although in my previous experience I had to put a using in my code.

I tried to set up a .cs file with partial classes to provide custom business logic behaviors to the generated classes and Intellisense does not recognize ar prompt with the generated classes.

I did as others have stated and brought up the properties panel of the Edmx model and fount the namespace. However, when I try to put it in a using statement, Intellisense does not recognize it.

Am I missing something here? EF can get very confusing and frustrating if one goes more than an inch or so below its generated surface.

1 Answer 1

1

Turns out that EF5 generates a model such that you do not need to have a "using namespace;" or a "namespace xxx"{} in the code file.

Just a simple xxx.cs file and each partial class definition you want to make: public partial class MyClass {

}

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.