Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pulling data from PERL to a rtf file

Status
Not open for further replies.

knlarson10

Programmer
Jun 29, 2012
1
0
0
US
So I am a fairly new to the PERL programming language and have ran into a problem so help would be greatly appreciated.

I am trying to create a rtf file that is generated from my Perl script that outputs numbers. I have figured out how to write a rtf file, but now I cannot pull the data. This is what I have tried.

use strict;

my $Perlscript = "/home/bunnies/Autoperl.pl";

my $file_to_open = $ARGV[0];

open (FILE, ">$file_to_open") || die("can't open $file_to_open: $!");

print FILE <<'END';
{\rtf1\adeflang1025\ansi\ansicpg125 (etc of the rtf script)
END
print wrote rtf;

use strict;
open (FILE, ">$Perlscript") || die("can't open $Perlscript: $!");
print $Events{HOG}{SIM2}{TIME};

close FILE;

Error message I receive Execution of /home/bunnies/part1rtf.rtf aborted due to compilation errors.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top