Help Me Understand this

G

George Kinley

Hi
I am learning to use "Format" function , most of the things I can understand
except how to write to different FILEHANDLE
use FileHandle;

OUTF->format_name("My_Other_Format");

OUTF->format_top_name("My_Top_Format");

I know this stunt works, but I cant understand how it works,

Another thing Which I would appreciate if some one can show how to add
commas in Integer number inside "format"

--
 
T

Tad McClellan

George Kinley said:
Subject: Help Me Understand this


Please put the subject of your article in the Subject of your article.

Another thing Which I would appreciate if some one can show how to add
commas in Integer number


perldoc -q commas

How can I output my numbers with commas added?

inside "format"


Use the FAQ answer and put the result in a scalar.

Treat the scalar as a string within the format.
 
J

Jim Keenan

George Kinley said:
Hi
I am learning to use "Format" function , most of the things I can understand
except how to write to different FILEHANDLE
use FileHandle;

OUTF->format_name("My_Other_Format");

OUTF->format_top_name("My_Top_Format");

I know this stunt works, but I cant understand how it works,

Let's first ask: Do you understand how to use Perl's built-in
select() function to change the default filehandle?

If not, then you probably shouldn't be attempting to use the more
complex, object-oriented interface provided by FileHandle.pm. What
are you attempting to accomplish that requires this approach as
opposed to select()?

Jim Keenan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top