I keep getting this error when i try to use SendAndScanFileAsync
"C:\KJ\Work\GEP Demos\CloudMersive Virus Scan Demo\CloudMersiveDemo\bin\Debug\netcoreapp3.1\CloudMersiveDemo.exe (process 22096) exited with code 0.
To automatically close the console when debugging stops, enable Tools->Options->Debugging->Automatically close the console when debugging stops.
Press any key to close this window . . ."
This is my code.
var clam = new ClamClient("localhost", 3310);
var fileBytes = File.ReadAllBytes("C:\\Users\\Karthik.Iyer\\Desktop\\sample_large_pdf\\A17_FlightPlan.pdf");
var scanResult = await clam.SendAndScanFileAsync(fileBytes);
switch (scanResult.Result)
{
case ClamScanResults.Clean:
Console.WriteLine("The file is clean!");
break;
case ClamScanResults.VirusDetected:
Console.WriteLine("Virus Found!");
Console.WriteLine("Virus name: {0}", scanResult.InfectedFiles.First().VirusName);
break;
case ClamScanResults.Error:
Console.WriteLine("Woah an error occured! Error: {0}", scanResult.RawResult);
break;
}
Any ideas ?
Thanks
Karthik