Command-line Script with -DIR parm not returning properly

Core FTP client questions and answers
Post Reply
sread1701
Posts: 3
Joined: Wed Apr 13, 2011 9:19 pm

Command-line Script with -DIR parm not returning properly

Post by sread1701 »

Within my app I'm creating a scripts to execute CoreFTP via the command line. I have one to PUT a file of a known name that works fine, but I have one that does a Directory listing via a command parm. it does the directory listing correctly but doesn't seem to exit properly, I call the .BAT file synchronously and the calling app hangs. Has anybody heard of this?

.BAT file for PUT: (which doesn't hang)

c:
cd c:\Program Files\CoreFTP
coreftp.exe -s -log <logfilename> -site Comdata_test -u <uploadfilename> -p /XV962/
exit %ERRORLEVEL%

.BAT file for directory list (which executes but then hangs)

c:
cd c:\Program Files\CoreFTP
coreftp.exe -s -log <logfilename> -site Comdata_test -dir /XV962/ <dirlistfilename>
ForumAdmin
Site Admin
Posts: 1011
Joined: Mon Mar 24, 2003 4:37 am

Post by ForumAdmin »

Use corecmd.exe instead of coreftp.exe (corecmd blocks until command completes).

Make sure <dirlistfilename> is a full path with filename, and that you have permission to that directory.
sread1701
Posts: 3
Joined: Wed Apr 13, 2011 9:19 pm

Post by sread1701 »

I don't see corecmd.exe - is it not part of the free download?
ForumAdmin
Site Admin
Posts: 1011
Joined: Mon Mar 24, 2003 4:37 am

Post by ForumAdmin »

It looks like it wasn't included in the new LE build. It will be in the next release.
sread1701
Posts: 3
Joined: Wed Apr 13, 2011 9:19 pm

Post by sread1701 »

Do you have a date for the next release? Or is there a way to get a copy of corecmd.exe for this release?
ForumAdmin
Site Admin
Posts: 1011
Joined: Mon Mar 24, 2003 4:37 am

Post by ForumAdmin »

build 1679, should be updated in the download area soon.
Post Reply