I want to have a generic copy function, with checks for existence, logging, etc. Part of it would be something like this:
Which works fine if $sourcefile is something like 'c:\foo.txt', but if we're doing a wildcard copy, $sourcefile might be 'c:\foo\*.*'. -e doesn't work on that, since (I assume) it's looking for a file literally named '*.*'.