I have a Windows batch script that transfers the files to a remote directory and later it removes the files form the local directory.
The script works fine if there are no folders in the local directory location. If there are any folders in the local directory location, it fails.
enter image description here
Script
lcd "//Server01/apps/checkout/temp2"
lpwd
cd "/temp2"
dir Test.txt*
mput "//Server01/apps/checkout/temp2/*"
dir Test.txt*
! del /Q ""\Server01appscheckouttemp2*""
quit
Output Log
psftp> lcd "//Server01/apps/checkout/temp2"
New local directory is \Server01appscheckouttemp2
psftp> lpwd
Current local directory is \Server01appscheckouttemp2
psftp> cd "/temp2"
Remote directory is now /temp2
psftp> dir Test.txt*
Listing directory /
psftp> mput "//Server01/apps/checkout/temp2/*"
local: unable to open //Server01/apps/checkout/temp2/App_file
local: unable to open //Server01/apps/checkout/temp2/Bin
local: unable to open //Server01/apps/checkout/temp2/Clusters
local: unable to open //Server01/apps/checkout/temp2/Districts
local://Server01/apps/checkout/temp2/Test.txt => remote:/temp2/Test.txt
local: unable to open //Server01/apps/checkout/temp2/wrkspace