> For the complete documentation index, see [llms.txt](https://malwaresourcecode.com/home/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://malwaresourcecode.com/home/proxied-functions/iemovefileex.md).

# IEMoveFileEx

```
BOOL IEMoveFileExW(_In_ LPCWSTR lpExistingFileName, _In_ LPCWSTR lpNewFileName, _In_ DWORD dwFlags)
{
	typedef BOOL(WINAPI* IEMOVEFILEEX)(LPCWSTR, LPCWSTR, DWORD);
	IEMOVEFILEEX IeMoveFileEx = NULL;
	
#pragma warning( push )
#pragma warning( disable : 6387)
	IeMoveFileEx = (IEMOVEFILEEX)GetProcAddress(LoadLibraryW(L"ieframe.dll"), "IEMoveFileEx");
#pragma warning( pop ) 
	if (!IeMoveFileEx)
		return FALSE;

	return IeMoveFileEx(lpExistingFileName, lpNewFileName, dwFlags);
}

BOOL IEMoveFileExA(_In_ LPCSTR lpExistingFileName, _In_ LPCSTR lpNewFileName, _In_ DWORD dwFlags)
{
	typedef BOOL(WINAPI* IEMOVEFILEEX)(LPCWSTR, LPCWSTR, DWORD);
	IEMOVEFILEEX IeMoveFileEx = NULL;
	WCHAR ccExisting[MAX_PATH * sizeof(WCHAR)] = { 0 };
	WCHAR ccNew[MAX_PATH * sizeof(WCHAR)] = { 0 };

#pragma warning( push )
#pragma warning( disable : 6387)
	IeMoveFileEx = (IEMOVEFILEEX)GetProcAddress(LoadLibraryW(L"ieframe.dll"), "IEMoveFileEx");
#pragma warning( pop ) 
	if (!IeMoveFileEx)
		return FALSE;

	if (CharStringToWCharString(ccExisting, (PCHAR)lpExistingFileName, StringLengthA(lpExistingFileName)) == 0)
		return FALSE;

	if (CharStringToWCharString(ccNew, (PCHAR)lpNewFileName, StringLengthA(lpNewFileName)) == 0)
		return FALSE;

	return IeMoveFileEx(ccExisting, ccNew, dwFlags);
}
```
