I am trying to FTP certain files from Client system to my own system using a C# application. As the backend is a mainframe PS, so normally I use DOS commands in client systems to login and then FTP the files. But now, I am thinking of automating it a little bit by creating an application that will create a batch file, execute it, FTP the files and then delete that batch file. All processes are working properly but there is only one problem and it is HUGE.
When I create the batch files, it is created successfully, but while executing it, it opens another instance of the .NET application and thus does not execute. But if I delete the application exe file, then the batch files run successfully and FTPies the files properly.
But I am not getting, why is it opening an instance of the application and does not run when the application file is present. Is there any way to get rid of this?
I am placing the exe in the client system, and ftp the files from mainframes to a drive in client system, then copy it to a mapped drive (U:\) which is our D Drive.
The batch files work correctly without the application file.
Please help me resolve the problem.