Go4Expert

Go4Expert (http://www.go4expert.com/)
-   Perl (http://www.go4expert.com/forums/perl/)
-   -   WriteFile Equivalent in perl (http://www.go4expert.com/forums/writefile-equivalent-perl-t16550/)

rag84dec 15Mar2009 20:04

WriteFile Equivalent in perl
 
HI all,
I want to write some data to a tape drive through perl.. one idea
is to use scsi commands to send data.But i want to write it through
filesystem with the usage of something like "WriteFile" in c++.Can
anyone help me ??..Is there something equivalent to "WriteFile"
in perl??...Any other idea to write data into Tape drive???

THanks

shabbir 15Mar2009 21:07

Re: WriteFile Equivalent in perl
 
Code:

#!/usr/local/bin/perl
open (MYFILE, 'abc.txt');
while (<MYFILE>) {
  chomp;
  print "$_\n";
}
close (MYFILE);

Not a PERL Expert but knows very little


All times are GMT +5.5. The time now is 02:53.