I am new to windows programming. I am coming across a problem where there is a pdf file open in browser and i need to save this file to a particular folder.
It is same as activity that we do in steps as ctrl +s; then change to desired folder and then click on save.

Is it possible to automate all these activity through a program.

One way which i tried is SendInput Keys, but it just open the dialog to save. how to proceed for rest?