I'm working right now on upgrading a VB.net Solidworks addin to a better version of it but in CSharp. I'm trying to migrate towards Entity Framework 6 when it comes to Database integration.

So I started a Visual Studio 2017 SwAddin C# project. You can follow my steps in this post [here](https://stackoverflow.com/questions/51823756/building-a-c-sharp-addin-for-solidworks/51824668#51824668). I then added the NuGet Package Entity Framework.

[![enter image description here](https://i.stack.imgur.com/q0sA2.png)](https://i.stack.imgur.com/q0sA2.png)

When this is done, i'm adding an ADO.net Entity Data Model to my project.

[![enter image description here](https://i.stack.imgur.com/YRogd.png)](https://i.stack.imgur.com/YRogd.png)

[![enter image description here](https://i.stack.imgur.com/nDAsf.png)](https://i.stack.imgur.com/nDAsf.png)

[![enter image description here](https://i.stack.imgur.com/PDcYJ.png)](https://i.stack.imgur.com/PDcYJ.png)

[![enter image description here](https://i.stack.imgur.com/VLPKg.png)](https://i.stack.imgur.com/VLPKg.png)

Then you may use a syntax like this one to Insert a new entry :

```
            Info_IndusEntities context = new Info_IndusEntities();

        WillyDemandes newDemande = new WillyDemandes()

        {

            PathModel = "ModelTest",

            ConfigName = "ConfigTest",

            Revision = 1,

            Priority = 2,

            Statut = "EnTest",

            WilmaTQ = true,

            WilmaRBRE = true,

            WilmaRBTK = true,

            WilmaTLS = true,

            GenerateBOM = true,

            PdfPage = "L;",

            ECO = "ECO #1234",

            SendingComputer = System.Environment.MachineName,

            Username = System.Environment.UserName,

            MailAddress = "myemail@mycompany.com",

            DateProduite = DateTime.Now

        };

        context.WillyDemandes.Add(newDemande);

        context.SaveChanges();

```

The problem is that this would work fine in any other projet. I tried a C# console project for example. But when it comes to trying this in an Addin, i'm getting the following error :

**'No connection string named 'Entities' could be found in the application config file.'**

[![enter image description here](https://i.stack.imgur.com/RCJXm.png)](https://i.stack.imgur.com/RCJXm.png)

I tried many things like changing the App.config "Build Action" to Embedded Ressource, or changing the "Copy to Output Directory" property to Always Copy but nothing seems to work.

This is a Class Librabry project and this is the Startup project of the solution. 

The content is in my config file :

[![enter image description here](https://i.stack.imgur.com/2fYNw.png)](https://i.stack.imgur.com/2fYNw.png)