Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

2
  • 1
    Thanks Jared. I think it is assigning the first subdirectory object to the objSubFolder variable, which is declared as a folder earlier in the function. Commented Mar 7, 2012 at 4:55
  • It's absolutely not equivalent to that C# code. objSubFolder will still be in scope and available after the loop and will be assigned to the first subfolder (if there was one). Which is probably the point of the code. I think the C# equivalent would be object objSubFolder; objforeach (objSubFolder in objFolder.SubFolders) { break; } // objSubFolder is still in scope here and pointing to the first member Commented Mar 7, 2012 at 12:58