There are plenty of posts about this error but I could not solve my problem with the answers there.
I've made an app to run with SQL Server through Entity Framework. The app is running on my PC with no problem , but when I send it to someone he gets this error
Cannot open database 'StorageDb' requested by the login. the login failed , login failed for user 'DESKTOP-....../User'
I've read that it has something to do with my connection string but I tried to change it and still it does not work. Here it is (in my app.config file):
<add name="Storage.Properties.Settings.StorageDbConnectionString"
connectionString="Data Source=.\SQLEXPRESS;Initial Catalog=StorageDb;Integrated Security=True"
providerName="System.Data.SqlClient" />
My DbContext file:
public StorageDbContext() : base("StorageDb")
{
....
}
I tried removing the string in the constructor or change it but still it doesn't work.