I’m creating a rather simple site for my company for tagging inventory and tags. This went fine and now we want to add a log-in element with usernames and passwords. This is being done in C# and ASP.NET 4, so a lot of this functionality is already built in.
I added a Login web part to a page which references a database in the App_Data folder. However, when I publish it to the app server, it doesn’t want to automatically put anything in the App_Data folder there and I get a SQL error when I try to login:
> A network-related or instance-specific error occurred while
> establishing a connection to SQL Server. The server was not found or
> was not accessible. Verify that the instance name is correct and that
> SQL Server is configured to allow remote connections. (provider: SQL
> Network Interfaces, error: 26 - Error Locating Server/Instance
> Specified)
Originally, when the program runs, it’s a simple tag scanning page that adds a field to a small table in another database. I’m curious if there’s a problem with the program referring to two databases and how C# works for this sort of authentication and if there’s an easier way to do this.
Did you install SQL Server on the new machine? Just a folder with a database is not enough in case of SQL Server.