int i ;
DWORD dw ;
String^ Source = "c:\\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:\\Program Files\\Program\\Test.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