I using(and have used in the past) the technique from HERE to allow me to produce a single stand alone exe for my application. By including referenced assemblies into the executable.
My newest application makes use of Entity Framework 6, it looks as though the dll is getting included into my executable but if I do not include it in the same folder as the executable my application crashes with an error.
System.InvalidCastException: Unable to cast object of type 'System.Data.Entity.Infrastructure.SqlCeConnectionFactory' to type 'System.Data.Entity.Infrastructure.IDbConnectionFactory'
I suspect this could be resolved if I moved my configuration out of App.config but am new to entity framework and am unable to decipher how to achieve this. If this is the solution how do I go about implementing it.
Update: I did manage to move my DB setup into a DbConfiguration object but this has not solved the problem.