How do I get %LocalAppData% in c#?
C#.NetC# Problem Overview
How do I get %LocalAppData%
in C#?
C# Solutions
Solution 1 - C#
If you would like to use an enumeration, try the following:
Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData)
Using this technique, you can also find all other Window's file paths (i.e Program Files, My Documents, etc).
Solution 2 - C#
Environment.GetEnvironmentVariable("LocalAppData")
for C#, since Visual Studio isn't a language, unless you're looking to get that variable in one of the VS dialogs or something.
Solution 3 - C#
Environment.SpecialFolder.LocalApplicationData