Hi guys i have written a windows service in c# in order to connect to database in every 10 minutes with entityframework it works fine in debug mode but when i release and install it on Local System Account it throws an exception:
The underlying provider failed on Open. Cannot open database "HCClient" requested by the login. The login failed. Login failed for user 'NT AUTHORITY\SYSTEM'.
my connectionstring:
add name="MyDataBaseName" connectionString="metadata=res:///Model.LocalModel.csdl|res:///Model.LocalModel.ssdl|res://*/Model.LocalModel.msl;provider=System.Data.SqlClient;provider connection string="data source=.;initial catalog=HCClient;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient"
And when i want to start service on Local Service or Network Service it returns me Error 5: Access is Denied although i have gave one of these permission to my executable service exe i have read all topic related to my error but none of them work
any help would be appreciated