I don't get an error. Everything compiles fine. About the headers, I have all the headers I need an more (because of other bits of code that are commented out, this is the only code that I haven't commented out) even so, the headers I am using are
The GetLastError() function returns 3 which means "The system cannot find the path specified." The path really does exist though, and I do have permission to change it.
Are you on a POSIX or on Windows? You are including headers from both APIs
What value does CopyFile return?
Are you sure that the folder test exists on drive L?
Thanks for the help, but I don't know what a POSIX i'm just running on win 7 with UAC disabled as an administrator. Yes L :\test\ exists, but if it didn't exist, could I do something to make it automatically create it?
EDIT: Woo it works. I have no idea what is different but it works. Thanks