title: How to find desktop path using C language?
body: <p>Can anybody please tell me how I can get the desktop path(environment variable) using C language commands.</p>
  
  <p>Scenario is that I want to save a file on desktop.What I can do is just to give a fixed desktop path and a filename to save the file. But after giving this fixed path ,my code will become rigid and will not work on anyother computer having different desktop path (environment variable). 
  My question is can I make my code generalize which can work on any windows based machine by capturing the environment variable of desktop , using C language?</p>
  
  <p>Regards</p>