Yes.
i think you are not familiar with windows programming. windows.h is one of the basic header we need.
this link contains some tutorials on windows programming.
http://www.winprog.org/tutorial/start.html[
^]
you can crate a directory by calling the function CreateDirectory.
later you can write the file to that directoryusing fopen(filename,"w") and using fwrite or fprintf or whatever.