On a windows machine in command prompt when i type "set" i get a list of environment variables. How do i access these from a c program. I am looking for the variable called "USERPROFILE"
On a windows machine in command prompt when i type "set" i get a list of environment variables. How do i access these from a c program. I am looking for the variable called "USERPROFILE"
There is a function called getenv you should look into.Originally Posted by Harman
"Owners of dogs will have noticed that, if you provide them with food and water and shelter and affection, they will think you are god. Whereas owners of cats are compelled to realize that, if you provide them with food and water and shelter and affection, they draw the conclusion that they are gods."
-Christopher Hitchens
thanks, as you can guess i am very new to c.