function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ADMIN DMIADMIN DMI 

Report tabs Excel Should display in column-wise

Hi 
 
I have 6 field in report tabs and when i run the report tab and go to printable view an excel sheet generated in that thos field are displayed in row wise but it should display in column-wise . 

Any ideas how/if this can be done?

Thanks in advance 
bob_buzzardbob_buzzard
Do you still want this to be exported to excel?  You can probably get this to save as a CSV file using Visualforce, but you can't just inject your code into the report export functionality.

Changing rows to columns is straightforward in Visualforce - this was the subject of my first blog post back in 2010:

http://bobbuzzard.blogspot.co.uk/2010/09/rotating-visualforce-table.html

If you change the contenttype of the visualforce page as follows:

<apex:page controller="MyCustomCtrl" contentType="text/plain/#test.csv">

then the page will be saved as csv.