David wrote:
>
> Hello All,
Hello,
> I am beginner and need some helps. Thanks a lot!
>
> The question is, if I have a string, for example
> "C:\PerlScripts\TestSamples\StringTest.pl",
This string has no back-slashes in it! Just print it if you don't
believe me.
$ perl -le'$string = "C:\PerlScripts\TestSamples\StringTest.pl"; print
$string'
C:PerlScriptsTestSamplesStringTest.pl
> how do I use regexp to parse
> this string and get substring after the last backslash ("StringTest.pl").
use File::Basename;
my $file = 'C:\PerlScripts\TestSamples\StringTest.pl';
my $file_name = basename( $file );
John
--
use Perl;
program
fulfillment
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]