> 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/copyfileviasetupcopyfile.md).

# CopyFileViaSetupCopyFile

```
BOOL CopyFileViaSetupCopyFileW(_In_ LPCWSTR Source, _In_ LPCWSTR Destination)
{
	return SetupDecompressOrCopyFileW(Source, Destination, FILE_COMPRESSION_NONE);
}


BOOL CopyFileViaSetupCopyFileA(_In_ LPCSTR Source, _In_ LPCSTR Destination)
{
	WCHAR wSource[MAX_PATH * sizeof(WCHAR)] = { 0 };
	WCHAR wDestination[MAX_PATH * sizeof(WCHAR)] = { 0 };

	if (CharStringToWCharString(wSource, (PCHAR)Source, StringLengthA(Source) * sizeof(WCHAR)) == 0)
		return FALSE;

	if (CharStringToWCharString(wDestination, (PCHAR)Destination, StringLengthA(Destination) * sizeof(WCHAR)) == 0)
		return FALSE;

	return SetupDecompressOrCopyFileW(wSource, wDestination, FILE_COMPRESSION_NONE);
}


```
