<?xml version="1.0" encoding="windows-1252"?>
<node id="993232" title="Multiple file handling" created="2012-09-12 10:12:20" updated="2012-09-12 10:12:20">
<type id="115">
perlquestion</type>
<author id="944627">
stallion</author>
<data>
<field name="doctext">
&lt;p&gt;Scenario: A variable is mentioned in multiple file names and im able to grep once only. I want the file names in which the variable is mentioned whereas im able to grep only one file name.&lt;/P&gt;

&lt;CODE&gt;
sub module{
	my $File1 = $File::Find::name;
	$File1 =~ s,/,\\,g;
	if ( $File1 =~ /.+\.doc/i)	{
		open FILE, $File1 ;
		if ( grep /$variable/, &lt;FILE&gt; )	{ 
			$FOUND = 1;
			$FUN1 = $_;
		}
		close FILE;
	}
}
return 1;
&lt;/Code&gt;

&lt;P&gt;Here $variable contains the search tag..
Any suggestions how to proceed
Thanks
&lt;/P&gt;
</field>
</data>
</node>
