M
mike
hi
i did a code to show the files in a directory
say
while(<test*.txt>)
{
print ;
}
it will show all the files with beginning with test and ending with .txt
but when i assigned it to a variable like this
$files = "test\*\.txt";
while(<"$files">)
{
print ;
}
it doesn't show the files.
Why is this so?
thanks
i did a code to show the files in a directory
say
while(<test*.txt>)
{
print ;
}
it will show all the files with beginning with test and ending with .txt
but when i assigned it to a variable like this
$files = "test\*\.txt";
while(<"$files">)
{
print ;
}
it doesn't show the files.
Why is this so?
thanks