how do i copy a sqlite database from visual studio studio?

So is there a specific place where the database file should, or must, be placed?

You can keep it in root directory of your project. If you like to follow specific folder structure, you can do that as well but there isn’t any restriction as to where you must store your sqllite db file.

Also, can I leave the database there while querying it from within the application code, or does it need to be copied to the user’s ApplicationData.Current.LocalFolder? That is what seems to be at least strong implied by that article, which shows code for doing so.

When you set a file property to Content in Build action, that file will be copied to your output directory, Release or Debug directory depending on what is your current build configuration and ApplicationData.Current.LocalFolder refers to the folder from which your application is running so it will work just by setting Build action to Content.

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top