I figured you might have issues with the colours.The colours would change with the overall theme of the desktop...
Anyway, I tried the 'dir -F' and all the directories ended in a slash.
I also tried running the the program , as is, and received a "illegal string-number conversion on line 1"