Install Directory of another program
Please support our C++ advertiser: Programming Forums
Thread Solved
![]() |
•
•
Posts: 9
Reputation:
Solved Threads: 0
how would I get the install directory of another program, the registry perhaps? (using HLDS as my directory to be found) (GET HLDS HERE!)
i fond the key which might be useful. (how would i open it?
i fond the key which might be useful. (how would i open it?
[HKEY_CURRENT_USER\Software\Valve\HLServer] "InstallPath"="C:\\hlds" "Full Name"="Half-Life Dedicated Server" "Region"="5"
Last edited by maxicube : Nov 21st, 2008 at 9:08 am.
Last edited by niek_e : Nov 21st, 2008 at 9:53 am.
Want better/more replies to your questions? Wrap your code in [code] [/code] tags!
•
•
Posts: 9
Reputation:
Solved Threads: 0
heh. didnt help me that much :/ but dad had some code for me
HKEY hKey; DWORD buffersize = 1024; char* hldsloc = new char[buffersize]; RegOpenKeyEx (HKEY_CURRENT_USER, "Software\\Valve\\HLServer",NULL,KEY_READ,&hKey); RegQueryValueEx(hKey,"InstallPath",NULL,NULL,(LPBYTE) hldsloc,&buffersize); RegCloseKey (hKey);
![]() |
Similar Threads
Other Threads in the C++ Forum
- Cannot Access Control Panel (Windows NT / 2000 / XP / 2003)
- can't access control panel (Viruses, Spyware and other Nasties)
- Finding directory of VB project dynamically (Visual Basic 4 / 5 / 6)
- How can I get a Program to Self Install itself in a given Directory? (C++)
- Which components of Visual C++ should i install (C++)
- nightmare trying to install windows (Windows NT / 2000 / XP / 2003)
Other Threads in the C++ Forum
- Previous Thread: Help... Link list problem
- Next Thread: Convert Binary to Decimal and from Decimal to Binary
•
•
•
•
Views: 368 | Replies: 2 | Currently Viewing: 1 (0 members and 1 guests)






Linear Mode