in reply to Re^3: Globbing for file in an unkown directory path only works first time in foreach loop?
in thread Globbing for file in an unkown directory path only works first time in foreach loop?
look at the output! it access the same file both runs, just the first time it finds it and the second time through the foreach loop it doesn't. I'll try and write it your way while you look
notice the array it is scanning through has 4257 as it's first element and it's second. It finds the 4257 file through the foreach the first time, but then one the foreach move to the second element in the array, which happens to be the exact same as the first element, it can't find the same file it just found.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Globbing for file in an unkown directory path only works first time in foreach loop?
by poj (Abbot) on Jan 29, 2016 at 20:43 UTC | |
by MarsRover (Novice) on Jan 29, 2016 at 20:52 UTC | |
by poj (Abbot) on Jan 29, 2016 at 20:54 UTC | |
|
Re^5: Globbing for file in an unkown directory path only works first time in foreach loop?
by Anonymous Monk on Jan 29, 2016 at 20:56 UTC |