in reply to Rename File Name in Array
It "doesn't work", because $ext is reset to "A" on every iteration. You need to declare and initialize that variable outside the loop.
To update $x->[0] after the rename, simply do $x->[0] = "USB" . $ext;.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Rename File Name in Array
by drodinthe559 (Monk) on Jul 20, 2008 at 11:25 UTC | |
by drodinthe559 (Monk) on Jul 20, 2008 at 19:39 UTC | |
by almut (Canon) on Jul 20, 2008 at 19:51 UTC |
In Section
Seekers of Perl Wisdom