Hello I have VB.NET System ; I wanna to make setup (.exe) for the program. The Program depend on SQL Server Database. How I can make it exe file with the database, and to install all the configuration on any PC. What I shall do according to the connection string ; since the server name will change? I don't have background in that ; any helpful articles or information ?

You asked many questions so I'll attempt to cover a few of them.

  1. Regarding the connection string:
    This is why long ago I would change my connection string to connect to 127.0.0.1 so the name was never an issue.
    There are so many articles about this so I'll offer one and you can find others.
    Read https://www.oreilly.com/library/view/adonet-cookbook/0596004397/ch01s07.html

  2. "make it exe file with the database"
    There are a few ways to do this but one method that worked well for me was to write code that would test the SQL connection and then see if the tables were there. If not, the code would create tables and insert the starter data.

  3. I also like this Quora answer:

    Use the publish wizard to publish a click once application.
    Under prerequisites make sure SQL Server Express is selected.

Read https://www.quora.com/How-can-I-deploy-my-project-attached-with-SQL-database-Im-using-VB-NET

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.