Have you tried encapsulating the filename in quotes for your filetest? The O/S you have uses question marks as single character wildcards. You don't get a filename match because it maches ONE character and doesn't try with "nothing" in that spot(as opposed to a NULL). I believe enclosing the name in quotes might be the trick in the short term.