I have a SAS programme which I have to submit to a remote site to execute. In order to preserve my log/print output, I use O/S commands to delete and create them (see below for code). This has worked fine for several months and continues to work on my test machine. But, for the past two weeks, the remote site has been unable to delete the log/print files after my programme has completed. They get an error saying that the file is still in use. They are storing the files on a network server, not a local machine.
Any advice/suggestions would be appreciated.
command = "rmdir /S /q &location_results";
call system (command);
command1 = "mkdir &location_results";
call system (command1);
I don't really understand how "filename outprint CLEAR;" would delete any listing output. Doesn't it just clear the output path for listing output without affecting listing output already created?
Another thought: Is there a reason for using "noxwait"? May be running things with options "xwait" and "synch" could resolve the issue. Just thinking that a change in the environment might have slowed down things so that you're now trying to delete stuff before it actually got released - just guessing here.