scorpion53061 wrote:
Yes exactly.
"Tom Spink" <s0******@sms.ed.ac.uk> wrote in message
news:do**********@scotsman.ed.ac.uk... scorpion53061 wrote:
I am trying using vb.net 2005 to backup my AIX Server to my Windows
computer. I thought using the new FTP control it would be a snap.
What it is suppose to do is connect to the server and start copying the
server to the backup folder creating directories and subdirectories as
needed.
I can get one file and I can create the directory and get those files
but getting the subdirectories and its files is where I am having
troubles. Has anyone tried to do something similar to this?
Hi,
Are you having trouble enumerating recursively through a directory?
-- Tom
OrElse what...
Hi,
Well, here is a function that recursively scans a directory.
Imports System.IO
Public Function RecurseDir ( szStartDir As String )
Dim strFiles As String() = Directory.GetFiles( szStartDir )
Dim strDirs As String() = Directory.GetDirectories( szStartDir )
For Each strFile As String In strFiles
DoSomethingWithFile( strFile ) ' Copy it?
Next strFile
For Each strDir As String In strDirs
DoSomethingWithDir( strDir ) ' Create it?
RecurseDir( strDir )
Next strDir
End Function
(Just a note: I haven't tested this at all.)
-- Tom
OrElse what...