Delete Specific Files in Remote File List
Posted: Mon Apr 13, 2015 9:58 am
I have a project that connects to a server and retrieves multiple files. On the get command I have a processed source files variable called "RemoteFiles". After the files are retrieved they are placed into a workspace. The project goes on to check the files that were retrieved (and are now in the workspace) to see if they have a footer record or not. If a file does have a footer record, then at the end of the project I want to delete that file from the remote server. If the file does not have a footer record, then I do not want to delete it from the remote server. Since all files that were retrieved from the remote server are included in the "RemoteFiles" file list (created on the get command), I cannot use ${RemoteFiles} as the input files variable in the delete command. How do I specify which files I want to delete?
For example, say I have the following two files in my RemoteFiles variable.
"/incoming/processing files/filename1.txt"
"/incoming/processing files/filename2.txt"
Say only file "filename2.txt" contains a footer record so I want to delete that file from the remote server. How would I do that?
I am using GoAnywhere Director version 4.6.2 and Windows Server 2012 operating system.
Thank you for any suggestions!
For example, say I have the following two files in my RemoteFiles variable.
"/incoming/processing files/filename1.txt"
"/incoming/processing files/filename2.txt"
Say only file "filename2.txt" contains a footer record so I want to delete that file from the remote server. How would I do that?
I am using GoAnywhere Director version 4.6.2 and Windows Server 2012 operating system.
Thank you for any suggestions!