0
votes

I have Visual Studio 2010 on Windows 7. My project is using the .net framework 3.5, but how do I go about referencing SP1 methods? The installer tells me to use Window's add / remove system programs, but that says .NET 3.5.1 is installed. I'm trying to follow the example at 'http://blogs.msdn.com/b/alexj/archive/2009/11/07/tip-41-how-to-execute-t-sql-directly-against-the-database.aspx' on executing a raw SQL command with entity framework, but I can not reference ".StoreConnection", as it's an SP1 addition.

Note that when I go to my project properties, I only have the option for .net 3.5 compact and .net 3.5. "SP1" is not listed anywhere.

Thanks in advance


I figured out my issue. I was trying to directly reference the common DBConnection as was shown to me for what Entity.Connection is. I needed to reference the EntityClient.EntityConnection specifically.

Thanks all

2

2 Answers

3
votes

You just reference the .NET 3.5 libraries. If your project targets the 3.5 framework then your references will be set to them. They get patched when you install SP1. Look at the versions of the .NET 3.5 libraries in your references. They should be that of the 3.5 SP1 libraries.

1
votes

If you have 3.5 SP1 installed, then you're ok. The version numbers didn't change, as shown by this Serverfault question.

To use anything from 3.5 (or 3.5SP1) you need to reference the appropriate assembly in your project. To do this, click on References, and add the appropriate reference from the dialog under .NET.