Code:
print "What is the last name of the employee? "; $LName = <STDIN>;
chomp($LName);
@EmpID = ("$LName");
print "\nWhat is the first name of the employee? ";
$FName = <STDIN>;
@EmpID = ("$LName", "$FName");
select(INFILE);
printf "\n@EmpID";print "Name added, thank you!"; #I DONT WANT THIS PRINT COMMAND TO BE IN THE FILE... I MERELY WANT IT TO SHOW ON THE SCREEN..
how can i get "Name added, thank you!" to appear on the screen, not printed in the file...i've tried putting
close(INFILE) after "printf "\n@EmpID";"
but what happens it an error pops up and says
print() on closed filehandle INFILE at C:/Employee ID 2.txt line 26, <STDIN> line 4.
C:/Employee ID 2.txt did not return a true value at - line 61, <STDIN> line 4.
and if it matters, I run this file from another using the "require" command