DeleteFile (String filePath)
Example
In this example, we are passing the required parameter to the function transformation object using a Variables object. We will be deleting a “Test.txt” source file which exists within a folder.
Where,
filePath = C:\Users\Kanwal.Azim\OneDrive - Astera Software\Desktop\Functions Documentation\Files\DeleteFile\Test.txt
Right-click on the function transformation object and select Preview Output. While the Data Preview will not generate an output, the existing file within the specified location will be deleted.