You are here

Newb: Coping an *.ini back and fourth

2 posts / 0 new
Last post
Last seen: 8 years 10 months ago
Joined: 2014-03-27 11:15
Newb: Coping an *.ini back and fourth

Hello all,

I have a database app that I would like to make portable. When it starts, it wants to read its configuration from an *.INI. The location for the *.INI is hard-coded in the single executable, it's always C:\Books-db\bdb.ini. The mapping for the actual database file is in that *.ini. The *.ini gets heavily modified in every session.

What I want to achieve is that I can keep both the *.exe and the database file on the stick. When it launches, I would like to copy the *.ini to C:\, to the folder it wants and after the program is done, I would like to copy the *.ini back.

I have tried the following in my launcher.ini:


It copies the *.ini down but it doesn't retrive it after the app finishes. What am I doing wrong (or can't it be even done)? Thanks for any suggestions.

And am a newb, please go easy on me if it's a silly question. Smile



darksabre76's picture
Last seen: 1 year 8 months ago
Joined: 2011-04-19 23:28

Odds are that it's not actually copying bdb.ini to that folder and the program is actually just creating it. The proper syntax to move a file is as follows:


Notice the file isn't mentioned on the righthand side of the setting. It is also worth mentioning that if it's writing directly to the root of C, it might need to be run as an administrator, but I'm not completely sure.

Log in or register to post comments