full directory listing from ftp? 
Author Message
 full directory listing from ftp?

Hi,

I'm still trying to find a way of getting a full directory listing using the
Inet control and ftp.
I would like to get a list of filenames and timestamps (like ls -l in ftp).

When I run ls -l in ftp on the command line, I get the desired results.
When I run Inet1.execute(, "ls -l") and then Inet.GetChunk(1024, vbString)
all that I get is the carriage return line feed combination.

Does anybody know anything about this problem?

Thanks,
Greg Wallis



Sun, 15 Jul 2001 03:00:00 GMT  
 full directory listing from ftp?
Quote:
>Does anybody know anything about this problem?

The Inet control is notorious for these types of problems.  Not that it cant
be done, but trying to figure it out with the horrible docs... And  besides,
I've always thought it was clunky with it's oddball "GetChunk" method.

You could try my xFtp control.  I guarantee it will give you a full list
with the xFtp.LIST() method.  And the list is returned in an event (Line by
line in Async mode or in one large string in Sync mode):

Private Sub xFtp1_OnDirList(ByVal DirList As String, ByVal Complete as
Boolean)
    if Not Complete then
            '============================
            ' Async? then put it line by line
            If xFtp.AsyncMode Then
                Text1.Text = Text1.Text & DirList & vbCrLf
            Else
                    '============================
                    ' Sync Mode; Its one big string
                    Text1.Text = DirList
            End if
    End if
End Sub

xFtp is free and comes with source code.

Brad

--

Free ActiveX Controls:
xStrings - Useful string methods and Regular Expressions!
xFtp - Commercial Quality Ftp client control.
Much, much more.
http://www.fp.gvn.net/bradley
-------------------------------------------------------

Quote:

>Hi,

>I'm still trying to find a way of getting a full directory listing using
the
>Inet control and ftp.
>I would like to get a list of filenames and timestamps (like ls -l in ftp).

>When I run ls -l in ftp on the command line, I get the desired results.
>When I run Inet1.execute(, "ls -l") and then Inet.GetChunk(1024, vbString)
>all that I get is the carriage return line feed combination.

>Does anybody know anything about this problem?

>Thanks,
>Greg Wallis



Sun, 15 Jul 2001 03:00:00 GMT  
 full directory listing from ftp?
Brad,
Your xFTP control is SUPER!
Greg


Thu, 19 Jul 2001 03:00:00 GMT  
 full directory listing from ftp?
i think that Inet doesn't support LS + options.
You can use WinInet API call FtpFindFirstFile and FtpFindNextFile to receive
all the info associated with the file (or dir)

Kosta



Sat, 28 Jul 2001 03:00:00 GMT  
 full directory listing from ftp?

Quote:

> i think that Inet doesn't support LS + options.
> You can use WinInet API call FtpFindFirstFile and FtpFindNextFile to receive
> all the info associated with the file (or dir)

> Kosta

What's wrong whit Dir??

Erik



Sat, 28 Jul 2001 03:00:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Full drive directory/file listing code wanted

2. FTP - Get directory list

3. ftp get a directory list

4. Parsing an FTP directory listing?

5. FTP directory listing >>Combo with ICP

6. Get ftp directory listing using ITC

7. ? - FTP Directory listing

8. directories and sub-directories in the list

9. Help: displaying hidden directories in directory list box

10. directories and sub-directories in to a list

11. Drive List and Directory List

12. Directory list in the list box

 

 
Powered by phpBB® Forum Software