I agree with @SUDHAKAR's response. Once file listener picks the file , it won't be available in the same folder either it will be moved to completed folder if file process successfully, if not , file will be remaned with .err extension.
As per your requirement, if you keep the file in same folder, file listener picks the same file again and again resulting to infinite loop.
currently i am doing time interval gap of one hour. Everyday the file path will change. So i want to handle this in Service file activity to skip processed file on next time process. here Listener will pick 24 times and skips next 23 times.
Here i want to keep file at same path once process is completed.
If my file name abc.jpg which I kept in a location say 'C:\MyFiles', the file listener will read the file from 'C:\MyFiles', process it, and move the file to 'C:\MyFiles\work_ListenerName\completed' folder. In case if it fails to process the file there will be a .err file created something as 'filename.<timestamp>.jpg.err' file in the same folder 'C:\MyFiles\work_ListenerName\completed'. In both the cases a .rpt file as 'abc.jpg.rpt' which will be page xml data that will show the status of the file whether processed or not.
If your expectation is to keep the file abc.jpg in the location 'C:\MyFiles' after the file is processed regardless of success/failure then this would be an enhancement and also it may effect the performance of File listener.
An enhancement request has been submitted for your use case after the subject matter experts shared their opinion on the thread. I have tagged the feedback request id in the related support case number section along with the issue description above. You may follow up with your Account Executive for updates on the progress of this request.
Is it possible to move the completed files to other folders which we define other than C:\MyFiles\work_ListenerName\completed' folder.
Can we customize the location where we can want save the completed files and Error files individually to their respective folders?. Like i want to save All Completed files to one Completed folder and Error files to Error Folder in 'C:\MyFiles' Location as example you mentioned.
initially i tried this logic but that file not creating at same path. so I have addded create connect file logic after service file process completes and its creating in shared path.
also one more logic imlimented in file listner like shared path location value is provided on basis of date time using Data pages. only when the actual process time comes i am providing valid share path and other time setting with some other path.