Jump to content
Xtreme .Net Talk

Portable App with Database


Recommended Posts

Guest DexterCamarillo
Posted

I have this problem when publishing and installing my app in another pc.

 

This program is a windows application written in c#. This comes with a local db (.mdf)

 

I made the Connection String to be relative, that is

 

Data Source=(LocalDB)\MSSQLLocalDB;AttachDbFilename=|DataDirectory|\SampleDb.mdf;Integrated Security=True" providerName="System.Data.SqlClient

 

In the publish setting I did not include the SQL Server 2012 Express Local DB.

 

Only the .Net Framework 4.7.2 is included.

 

Then I encountered this error when running the app in another PC

 

error: 52: Unable to locate a Local Database Runtime installation. Verify that SQL Server Express is properly installed and the Local Database Runtime feature is enabled

 

 

 

What could I be missing out here. This is my first time publishing an application.

 

Thanks for the answer.

 

Continue reading...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...