http://qs1969.pair.com?node_id=139961


in reply to Opening a Directory

Can you show me how to validate the existence of a directory?

You want the file test operators, specifically -d.

If the directory name has a space in between, what should I do?

Nothing special, as long as you have the whole dir name instead of just the first word.

And how to capture all the files under a directory?

opendir, readdir, closedir.

And God bless all Monks!

Which one?

--
:wq