Help Me Understand this

Discussion in 'Perl Misc' started by George Kinley, May 13, 2004.

  1. 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"

    --
     
    George Kinley, May 13, 2004
    #1
    1. Advertising

  2. George Kinley <> wrote:

    > 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.


    --
    Tad McClellan SGML consulting
    Perl programming
    Fort Worth, Texas
     
    Tad McClellan, May 13, 2004
    #2
    1. Advertising

  3. George Kinley

    Jim Keenan Guest

    "George Kinley" <> wrote in message news:<QaFoc.16263$>...
    > 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
     
    Jim Keenan, May 13, 2004
    #3
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ketul Patel
    Replies:
    1
    Views:
    731
    Alvin Bruney
    Nov 29, 2003
  2. JV
    Replies:
    1
    Views:
    348
  3. =?Utf-8?B?VmlzaHdhbmF0aGFuIFJhbWFu?=

    Cache vs Application State -- Pls help understand

    =?Utf-8?B?VmlzaHdhbmF0aGFuIFJhbWFu?=, Jul 10, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    3,051
    =?Utf-8?B?bG9uZG9uIGNhbGxpbmc=?=
    Jul 10, 2005
  4. Replies:
    4
    Views:
    462
    Joerg Jooss
    Aug 31, 2005
  5. Leo Smith
    Replies:
    5
    Views:
    617
    Oliver Wong
    May 26, 2006
Loading...

Share This Page