Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2007
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Exporting TableHeadings to Excel

  • To: mathgroup at smc.vnet.net
  • Subject: [mg76974] Re: [mg76936] Exporting TableHeadings to Excel
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Thu, 31 May 2007 03:18:21 -0400 (EDT)
  • Reply-to: hanlonr at cox.net

Use either

aa = Prepend[data, {"Item", "Heading1", "Heading2"}];

or

aa = Join[{{"Item", "Heading1", "Heading2"}}, data];


Bob Hanlon

---- Dean Williams <deanwilliams at mac.com> wrote: 
> 
> Using the example below, I am trying to export the TableHeadings to
> accompany the data into Excel.
> 
> However, when I open Excel, the TableHeadings are lost.
> 
> Is there a way to export the TableHeadings and data together?
> 
> Regards
> 
> Dean
> 
> 
> data = {{"Item1", 1, 2}, {"Item2", 3, 4}}
> 
> aa = TableForm[data,
>   TableHeadings -> {None, {"Item", "Heading1", "Heading2"}}]
> 
> Export["testxls.xls", aa]
> 
> 



  • Prev by Date: Re: v6: cursor behaviour with arrow keys
  • Next by Date: Re: Re: Re: asymptotics
  • Previous by thread: Re: Exporting TableHeadings to Excel
  • Next by thread: Re: Exporting TableHeadings to Excel