> On Nov 19, 2017, at 5:24 PM, Christian Schmitz
> <[email protected]> wrote:
>
> Well, I think you could move to CURLSFileInfoMBS class for FTP listing
> instead.
> It does parsing better than FTPParse class.
Thank you. I tried your example. It works great with FTP. Ironically, that
is where I don’t need it for the purposes of this project. Again, my aim is
just to get the remote size in advance, so I can tell SFTP to skip, and not
try to append, any completed file.
For SFTP, curl returns Error 18 (closed with file length remaining). If I take
out the wildcard stuff, I get error 0 but blank FileInfo—same with FTP.
Now, I have no problem getting the string from OutputData. So after splitting
it into an array at the endOfLines (called “Stuff” here, with f as the local
file), I can do this:
Dim x, u as integer
Dim canUpload as Boolean
u=ubound(Stuff)
For x=0 to u
If instr(Stuff(x),f.name)>0 then
//exists on server
dim s as string=str(f.length)
if instr(Stuff(x),s)=0 then
//needs appending
canUpload=true
else
//it finished
canUpload=False
end if
exit
else
//haven’t started it yet
canUpload=true
end if
Next
If canUpload=true then
//perform
else
//skip and go to next file in batch
End if
Now, this actually works in my tests, but I also feel that it would get me a
special exhibit at the World Museum of Kludges, and I’m not that desperate to
be famous. :-) The other approach is to keep my own log in ApplicationData,
and work from that when trying to resume.
-----
"Drama is life with the dull bits cut out."
-Alfred Hitchcock
Jerry Fritschle
[email protected]
_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
[email protected]
https://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info