Recurse through a Directory structure

Category:
Files and Directories
Type:
Snippets
Difficulty:
Intermediate
Author:
Scott

Version Compatibility: Visual Basic 6

More information:
Requires you have 'scrrun.dll' VBScript dll installed on your PC, which come with VB6, but can be used with VB5.

As written, the function just prints the child directories and files, but you can modify it to return an array or collection of names if you want.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: