Hello everyone!

I just can not cope with a seemingly foolish error. It seems to google already, but many of the fixes that were offered on Stackoverflow did not fit. Still just did not have time to try, because some of them require enough time and digging into the system. I do not think that everything is so difficult.

In general, I created a Windows Forms test project and tried to connect to MS SQL Server Compact 4.0 via ADO.NET EDM. However, when I try to get information from the table, I get the above error.

Connection string quote:

<connectionStrings> <add name="MyBDEntities" connectionString="metadata=res://*/testModel.csdl|res://*/testModel.ssdl|res://*/testModel.msl;provider=System.Data.SqlServerCe.4.0;provider connection string=&quot;data source=C:\Users\Work\Documents\MyBD.sdf&quot;" providerName="System.Data.EntityClient" /> <add name="TestADOApp2.Properties.Settings.MyBDConnectionString" connectionString="Data Source=|DataDirectory|\MyBD.sdf" providerName="Microsoft.SqlServerCe.Client.4.0" /> </connectionStrings> 

Hope that maybe you can help.

Thank you in advance!

Closed due to the fact that off-topic participants PashaPash , aleksandr barakin , tutankhamun , Nick Volynkin , Peter Olson August 17 '15 at 7:48 .

It seems that this question does not correspond to the subject of the site. Those who voted to close it indicated the following reason:

  • "The question is caused by a problem that is no longer reproduced or typed . Although similar questions may be relevant on this site, solving this question is unlikely to help future visitors. You can usually avoid similar questions by writing and researching a minimum program to reproduce the problem before publishing the question. " - PashaPash, aleksandr barakin, tutankhamun, Nick Volynkin, Peter Olson
If the question can be reformulated according to the rules set out in the certificate , edit it .

    1 answer 1

    Yes, I hurried. Everything was decided.

     <connectionStrings> <add name="MyBDEntities" connectionString="metadata=res://*/testModel.csdl|res://*/testModel.ssdl|res://*/testModel.msl;provider=System.Data.SqlServerCe.4.0;provider connection string=&quot;data source=|DataDirectory|\MyBD.sdf;password=******&quot;" providerName="System.Data.EntityClient" /> </connectionStrings> 

    Such a configuration works fine. I propose to close the topic.