ahmed.zubaca
ahmed.zubaca

Reputation: 127

How to create Setup.exe with SQL Server Express database

I am working on a Winforms application in C# using .NET 6.0.

The application has a SQL Server database with four tables. I have completed it and created setup.exe which successfully installs the application on my computer and works perfectly with the SQL Server Express database.

However, when I install it on another computer, I have problem to establish and connect database. I followed several instructions with no success. I even changed platform to .NET Framework 4.8 and followed tutorial to create localDb.

It works fine if I have only one table and one form with datagridview which follows table from database. But when I try interaction with other forms and tables it does not work.

It seems to me that only way is to install SQL Server Express on another computer and create the same connection string and same table, which I believe could not be the truth.

I saw a number of questions addressing the same problem, but there is no answers that solve it. I would be very thankful If anybody could suggest tutorial or article which addresses this topic.

Upvotes: 1

Views: 614

Answers (0)

Related Questions