Common practice under Windows is for a program to create a folder within Application Data and drop stuff in there. The proper way to get the path to Application Data is through SHGetFolderPath. It'll look something like this:Shiru wrote:tepples, I can modify it if you have certain request - like 'put the file in .. dir'
Code: Select all
char appData[MAX_PATH];
// SHGetFolderPath documented at
// http://msdn.microsoft.com/en-us/library/bb762181%28v=vs.85%29.aspx
// It fills appData with the path to the folder.
HRESULT err = SHGetFolderPath(NULL,
CSIDL_APPDATA|CSIDL_FLAG_CREATE,
NULL,
0,
appData);
// Then create a folder inside appData into which your app drops stuff.The source code for Lockjaw demonstrates one way to do this.