Click here to Skip to main content
16,006,605 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Access Denied Error Pin
Larry Mills Sr16-Jul-08 9:20
Larry Mills Sr16-Jul-08 9:20 
GeneralRe: Access Denied Error Pin
Perspx16-Jul-08 10:00
Perspx16-Jul-08 10:00 
GeneralRe: Access Denied Error Pin
led mike16-Jul-08 10:42
led mike16-Jul-08 10:42 
GeneralRe: Access Denied Error Pin
Larry Mills Sr16-Jul-08 11:19
Larry Mills Sr16-Jul-08 11:19 
GeneralRe: Access Denied Error Pin
Mark Salsbery16-Jul-08 12:14
Mark Salsbery16-Jul-08 12:14 
GeneralRe: Access Denied Error Pin
led mike16-Jul-08 12:18
led mike16-Jul-08 12:18 
GeneralRe: Access Denied Error Pin
Larry Mills Sr16-Jul-08 13:51
Larry Mills Sr16-Jul-08 13:51 
GeneralRe: Access Denied Error Pin
Mark Salsbery16-Jul-08 14:13
Mark Salsbery16-Jul-08 14:13 
You'll have the same problem writing to the root.

Larry Mills Sr wrote:
the reason I need to place the root tree at "c:\\" is because my program only knows that location


That's why the proper method is to use the known system folders, which vary by OS.
There's API's to get these folders. The installer should create subfolders with
the appropriate permissions and that's where your app should write app data.
Installers should know about these folders just like they know about the Program Files folder.

For example, on Vista you can use SHGetKnownFolderPath() to get the following paths at runtime:
FOLDERID_RoamingAppData - per user roaming application data
FOLDERID_LocalAppData - per user local application data
FOLDERID_ProgramData - common application data

Mark

Mark Salsbery
Microsoft MVP - Visual C++

Java | [Coffee]

GeneralRe: Access Denied Error Pin
Larry Mills Sr17-Jul-08 17:55
Larry Mills Sr17-Jul-08 17:55 
GeneralRe: Access Denied Error Pin
led mike16-Jul-08 12:17
led mike16-Jul-08 12:17 
Questionhowto Post Message Pin
aei_totten16-Jul-08 7:52
aei_totten16-Jul-08 7:52 
AnswerRe: howto Post Message Pin
Cedric Moonen16-Jul-08 8:06
Cedric Moonen16-Jul-08 8:06 
GeneralRe: howto Post Message Pin
Stephen Hewitt16-Jul-08 13:09
Stephen Hewitt16-Jul-08 13:09 
GeneralRe: howto Post Message Pin
Cedric Moonen16-Jul-08 20:36
Cedric Moonen16-Jul-08 20:36 
GeneralRe: howto Post Message Pin
Stephen Hewitt16-Jul-08 20:41
Stephen Hewitt16-Jul-08 20:41 
AnswerRe: howto Post Message Pin
CPallini16-Jul-08 8:23
mveCPallini16-Jul-08 8:23 
AnswerRe: howto Post Message Pin
krmed16-Jul-08 10:25
krmed16-Jul-08 10:25 
AnswerRe: howto Post Message Pin
ThatsAlok17-Jul-08 22:13
ThatsAlok17-Jul-08 22:13 
Questionarray 2d search Pin
gordon305616-Jul-08 6:09
gordon305616-Jul-08 6:09 
AnswerRe: array 2d search Pin
Luc Pattyn16-Jul-08 6:29
sitebuilderLuc Pattyn16-Jul-08 6:29 
GeneralRe: array 2d search Pin
gordon305616-Jul-08 6:48
gordon305616-Jul-08 6:48 
AnswerRe: array 2d search Pin
Mark Salsbery16-Jul-08 6:33
Mark Salsbery16-Jul-08 6:33 
GeneralRe: array 2d search Pin
Luc Pattyn16-Jul-08 6:51
sitebuilderLuc Pattyn16-Jul-08 6:51 
GeneralRe: array 2d search Pin
Mark Salsbery16-Jul-08 6:55
Mark Salsbery16-Jul-08 6:55 
GeneralRe: array 2d search Pin
Luc Pattyn16-Jul-08 7:22
sitebuilderLuc Pattyn16-Jul-08 7:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.