north2012
Member level 3
- Joined
- Apr 1, 2013
- Messages
- 63
- Helped
- 1
- Reputation
- 2
- Reaction score
- 1
- Trophy points
- 1,288
- Activity points
- 1,813
I am using Microsoft Visual Studio 2013 Ultimate.
I have one C# application connected with WSN to collect and save all sensor readings in database. It is working fine and stable.
Later I decided to add ASP.NET application (developed in the same software) so other computers in LAN can access my page and check measurements. I have one web form with few labels and buttons to ensure move forward and backward through the database table. It is working fine.
The problem is that I can not access in the same time to the database from C# application and web application deployed on the server. For example, if I start C# app before web it is OK and I can use it to collect new data but if I try to access in the same time from web I have error in browser:
Cannot open database "C:\USERS\USER\DOCUMENTS\VISUAL STUDIO 2013\PROJECTS\HOME SENSOR DATABASE\HOME SENSOR DATABASE\HOME SENSOR.MDF" requested by the login. The login failed. Login failed for user 'NT AUTHORITY\SYSTEM
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.SqlClient.SqlException: Cannot open database "C:\USERS\USER\DOCUMENTS\VISUAL STUDIO 2013\PROJECTS\HOME SENSOR DATABASE\HOME SENSOR DATABASE\HOME SENSOR.MDF" requested by the login. The login failed. Login failed for user 'NT AUTHORITY\SYSTEM'
Can you recognize what is the problem?
Thanks.
I have one C# application connected with WSN to collect and save all sensor readings in database. It is working fine and stable.
Later I decided to add ASP.NET application (developed in the same software) so other computers in LAN can access my page and check measurements. I have one web form with few labels and buttons to ensure move forward and backward through the database table. It is working fine.
The problem is that I can not access in the same time to the database from C# application and web application deployed on the server. For example, if I start C# app before web it is OK and I can use it to collect new data but if I try to access in the same time from web I have error in browser:
Cannot open database "C:\USERS\USER\DOCUMENTS\VISUAL STUDIO 2013\PROJECTS\HOME SENSOR DATABASE\HOME SENSOR DATABASE\HOME SENSOR.MDF" requested by the login. The login failed. Login failed for user 'NT AUTHORITY\SYSTEM
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.SqlClient.SqlException: Cannot open database "C:\USERS\USER\DOCUMENTS\VISUAL STUDIO 2013\PROJECTS\HOME SENSOR DATABASE\HOME SENSOR DATABASE\HOME SENSOR.MDF" requested by the login. The login failed. Login failed for user 'NT AUTHORITY\SYSTEM'
Can you recognize what is the problem?
Thanks.