Databases in App_Data do not save data
I have a sql database in my app_data folder and my connection string looks like this:
Server=.\SQLExpress;AttachDbFilename=|DataDirectory|wikipediamaze.mdf; Trusted_Connection=Yes;
I am using Fluent Nhibernate and everything displays correctly. I can connect to the database just fine and even update and insert rows with no problem.
My problem is that after I stop debugging, none of my data exists. I checked to put my database in bin folder and create a new instance for every application run, but this is not the case.
Does anyone have any other suggestions? I spent 2 nights trying to figure this out.
Thanks!
0
a source to share
2 answers