Library tutorials & articles
Getting System Folders Easily via API
Introduction
So you wrote an application? Great! Commercial? Freeware? Shareware? Awesome! Tested it? Great!
You send your baby on the web to millions of download users and get a ton of mail from users of specific Operating Systems or people that have used Tweaking programs that you get errors.
This is one of the most common errors that may happen to many of you who code in a way which you use static paths.
This can be easily avoided by plugging in a few functions which will do you the job of getting those paths no matter what Win32(and soon Win64) OS is running.
This article explorers the three most common paths which are used by developers:
- Windows Directory [Nope its not just c:\windows]
- System Directory
- Temporary Files Directory
Related articles
Related discussion
-
Automating Excel from VB6.0
by epurdy (0 replies)
-
VB6 system conversion using VBA to Word 2007
by b.macgregor@vodamail.co.za (0 replies)
-
video not working with visual basic
by Jupiter 2 (9 replies)
-
Hyperterminal Data
by sengreen (1 replies)
-
vb6 - custom font
by Ruffsta3 (0 replies)
Related podcasts
-
Christian Beauclair
14 mai 2008 (�mission #0074) ::.Christian Beauclair: Stratégies de migration VB6 vers .NET Nous discutons avec Christian Beauclair des stratégies de migration VB6 vers .NET. Entre autres, nous discutons comment utiliser le "VB 6 Code Advisor" et le "Interop Forms Toolkit" pour ajouter la puiss...
When you need the Temp folder, the easy (and clean .Net way) is to use: Path.GetTempPath()
it will still work for change dpaths... i used TweakXP to try it out on a few VMs and it worked fine... as far as other languaegs go... i only get English versions of OS's from MS so i dont know what the effects are, i suppose its teh same but i aint sure... amybe someone else maybe able to tell you.
so if the user changes their dir from say C:\WinNT\System32\ to C:\WindowsNT\System Files\ would i still be able to get the Windows DIR and System DIR?
also what about foreign languages?
sorry i couldnt reply earlier, I only saw my post now!
thank-you for your kind words!
Hey,
I must say this is EXTREEMLY useful for a nutcase like myself!
I infact had the exact problem you said most people have.
Thanks alot! It really helps!
This thread is for discussions of Getting System Folders Easily via API.