Hello, Im new to the list, after unsuccsesfully searching the archives I decided to post here.  I'm having problems with getting the size for an executable using the win32 API's CreateFile call.
if ((fhandle = CreateFile(filename.c_str(),0, FILE_SHARE_WRITE, 0,OPEN_EXISTING,0,0)) == INVALID_HANDLE_VALUE)
it always returns INVALID_HANDLE_VALUE, this happens also to be the exe that im executing, any thoughts ?