How to call a function with parameters from another fucntion

Very simple question maybe, but how do I call a function with parameters inside another function?
How do I call Download function in DownloadButtonClicked function?

void FDownloader::Download(FString File)
{
	DownloadAsset->DownloadFile(File);
}

void FDownloaded::DownloadButtonClicked()
{

}

Just as-is: Download("filename");.

Although you should definitely check out a C++ course instead :slight_smile:

It’s possible that you are experiencing problems because of a typo. Line 6 “FDownloaded” rather than “FDownloader”

void FDownloader::Download(FString File)
 {
     DownloadAsset->DownloadFile(File);
 }
 
 void FDownloader::DownloadButtonClicked()
 {
     FString filename = "MyFileName";
     Download(filename);
 }

Ahh yes my function name was different. It was a stupid typo. Got it, thanks for pointing out :D.