- Destination Pascal Script: Begin psExitCode:= 1; // ... add your code here psVIA := psVIA + 1; psLogWrite(1, '', 'Valid file available: ' + psFilePath + psFileName); End. - On Rule Begin Pascal Script: Begin psExitCode:= 1; psLogWrite(1, '', 'On Rule Begin'); // Set Variable Integer A to Zero psVIA := 0; End. - On Rule End Pascal Script (with email memory): Begin psExitCode := 0; // ... add your code here If (psVIA = 0) Then Begin If psVIB = 0 Then Begin psVIB := 1; psExitCode := 1; psLogWrite(1, '', 'Do send email, valid file not found'); End Else psLogWrite(1, '', 'Valid file not found, email has already been sent'); End Else psVIB := 0; End. - On Rule End Pascal Script (without email memory): Begin psExitCode := 0; // ... add your code here If (psVIA = 0) Then Begin psExitCode := 1; psLogWrite(1, '', 'Do send email, valid file not found'); End Else psVIB := 0; End.