MoveFileEx Problem

Posted by rajivpradeep on Stack Overflow See other posts from Stack Overflow or by rajivpradeep
Published on 2010-06-07T07:16:05Z Indexed on 2010/06/07 7:22 UTC
Read the original article Hit count: 312

Filed under:
int i ;
DWORD dw ;
String^ Source = "c:\\ProtectedFlash\\Program\\test.exe" ;
String^ Destination = "c:\\Program Files" ; // move to program Files Folder

//pin_ptr<const wchar_t> WSource = PtrToStringChars(Source);
// pin_ptr<const wchar_t> WDestination = PtrToStringChars(Destination);

i = MoveFileEx(L"c:\\ProtectedFlash\\Program\\ProtectedFlash.exe",L"c:\\Program Files",MOVEFILE_REPLACE_EXISTING) ;
dw = GetLastError() ;

return 0; 

The status dw is valued as 5 , when i run the program.

Whats the error

© Stack Overflow or respective owner

Related posts about c++-cli