Dear Jeff,
#The below is my complete code.
# I am trying to parse all XML file in a single folder.
# So I want list of XML file Names Only to write a batch file
- open (F1, ">parseAll.bat") ||die ("Cant open the file $!");
-
my $dir = $ARGV[0]; # Folder Path
-
foreach $file (<$dir*.xml>)
-
{
-
print "$file\n";
-
$err=(split /\./, $file)[0];
-
-
$errlog="$err".".par"; #Assigning a value same XML name but exten.par
-
$_ .= "\\\\192.168.50.23\\software\\AllProjectMaster\\Projects\\Y2007\\2007-09\\SWR0300_Scon\\Parser\\nsgmls -D \\\\192.168.50.23\\software\\AllProjectMaster\\Projects\\Y2007\\2007-09\\SWR0300_Scon\\Parser -f $errlog \\\\192.168.50.23\\software\\AllProjectMaster\\Projects\\Y2007\\2007-09\\SWR0300_Scon\\Parser\\xml\.dcl $file\n";
-
}
-
print F1 $_;
-
close F1;
-
system("parseAll.bat");
-
unlink("parseAll.bat");
Thanks,
Raam.
Please suggest.
Well, first, please do not top post when you reply. Place your new message
below the quoted message you are replying to. Otherwise,
?
about
talking
are
you
what
know
anyone
will
how
Next, you posted a question saying that your code worked fine when it was a .pl extentioned file. Then, when you "converted" it to .exe, it stopped working. I asked you in my reply
what you were using to do the conversion to an exe file and you still
have not answered that question.
According to your posting, the conversion may have caused your code not to work.
What you have to keep in mind is that the module or program that you used to convert the script to a .exe is not perfect. The process is not guaranteed to work, nor is it foolproof. There is always a chance for problems. I have not used either method and don't see a need to since you can execute perl scripts without them being .exe files.
Regards,
Jeff