Database gone after publishing

davy_g

Well-known member
Joined
Jul 18, 2007
Messages
63
Location
Belgium
Programming Experience
Beginner
Hi all,

I've made my first version of a program which is based on an Accessdatabase. I now want to let my girlfriend use it and pressed Publish. It asked me if I wanted to install it from a unc share, website or cd-rom and I picked cd-rom.
I've chosen the option not to check for updates and published my app.

I've tried to install the app by clicking setup.exe and it created a shortcut in my startmenu which is ok. Now when I run it it says that it cannot find my database.
I also do not find it in the installdirectory.
The error is following:

System.Data.OleDb.OleDbException: Could not find file 'C:\Documents and Settings\Davy\Local Settings\Apps\2.0\Data\6M1O9467.P35\EZCMRL75.MWK\uren..tion_1b92957e78fea067_0001.0000_ea6fc97507364811\Data\Uren.mdb'.

Why does it search in such a weird directory?
In the creation of my project I've chosen to copy the database to my project so it is really in.
Did I do anything wrong?
I just want to have 1 exe-file and the database and that should work.

How do I do that? I've tried many things but nothing seems to work well.

Thanks
 
Last edited:
Ok now I see my problem. In my window in the right I had selected all files and there my db was in. When I went back to my normal view the db was gone, probably because I copied it a few times (due to new fields etc).
Now I added it again and it now seems to work.

Strangeeeee
 
OK I have one question left :)

How do I only get the exe-file and database?

In my startmenu I have a link to file:///C:/Documents%20and%20Settings/Davy/My%20Documents/Urenregistratie/Urenregistratie.application#Urenregistratie.application, Culture=neutral, PublicKeyToken=1b92957e78fea067, processorArchitecture=msil

So where is my exe?
 
Last edited:
OK already solved that issue also. After some experiments it seems that in the directory of which the version is published, there is a urenregistratie.exe.deploy and uren.mdb.deploy.
When I rename the files and take away the .deploy-extension, the app seems to work ok.

Damn, why do I always get the solution when I just posted my topic :s

Anyway I'll leave it standing here in case someone else needs this info :)
 
Back
Top