This is topic Programming-related mayfly in forum Books, Films, Food and Culture at Hatrack River Forum.


To visit this topic, use this URL:
http://www.hatrack.com/ubb/main/ultimatebb.php?ubb=get_topic;f=2;t=057748

Posted by C3PO the Dragon Slayer (Member # 10416) on :
 
I am trying to get a piece of software to install on a computer that locks access to the C drive. I can get as far as installing the software, but it doesn't run because it looks for files in the C drive when the program starts, and since it can't find them, it aborts. I have learned that the software reads the variable set with CSIDL_COMMON_DOCUMENTS to determine where to look for the file it needs to read. If I can somehow change this variable, I can put the files it needs in a different directory and have the software run seamlessly.

So what I'm asking is if anyone knows if it's possible to change this CSIDL_COMMON_DOCUMENTS variable (apparently the WinAPI uses it), preferably with C++ or Java. It is apparently the final obstacle to getting this software running. If not, I'll keep at it with my google-fu, but I've been at this for weeks.
 
Posted by ricree101 (Member # 7749) on :
 
Here's an article on environmental variables on XP. IIRC, changing them is mostly the same on vista.
 
Posted by King of Men (Member # 6684) on :
 
quote:
have the software run seamlessly
Famous last words! You should not believe that any bug is the last bug until you've actually made the software run. [Smile]

Point to note: This is not very programming-related, it's administrative.

Further point: If anything else in your system relies on that env variable, you're likely to break it. Make a mental note, and perhaps a system-restore, in case you see any weird behaviour elsewhere.
 
Posted by HollowEarth (Member # 2586) on :
 
CSIDL_COMMON_DOCUMENTS isn't an environmental variable, but it typically points to C:\Documents and Settings\All Users\Documents. I'd bet that it is possible to change it, but probably not without administrator access, which you probably don't have since you can't write to the C drive.

Perhaps you should consider that one of the reasons that C drive access is blocked is probably to prevent you from installing things?
 


Copyright © 2008 Hatrack River Enterprises Inc. All rights reserved.
Reproduction in whole or in part without permission is prohibited.


Powered by Infopop Corporation
UBB.classic™ 6.7.2