To all,

I'm writting a web based application which lets the user query various parts of out database and output the data to your browser. Such data is outputted in a table format to make for easy readability. Some of the attributes that you may see are: UserID, TestResult, Create_Date, Create_Time, Release, UserComments, etc (there are many, many others).

Anyway, I also output this data to a XLS file so the user can save and manipulate this data outside of the application. Currently, I just open a file handle (call it XLS) and so something like print XLS "$UserID\t$TestResult\t$Create_Date\t$Create_Time\t$Release\t$UserComment\n" Which is most cases works fine, but sometimes, some of the data is a list of multiple thing but in the xls cell, it comes out as one long string.

Question 1: Is there a way to add in a "newline" in a XLS cell via using print statement above? I'm obviously not using any Excel modules, so I'm guessing I'll have to do that or are they any quick workarounds ?

Question 2: Are there any recommended modules that I can output this some data to either a .txt format or .doc format ?

Thank in advance all !!


In reply to Formatting text when outputting to a XLS file by TASdvlper

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.