COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: midhl on 13 Mar 2009 06:00:06 AM

Title: Exporting Report Output to EXCEL
Post by: midhl on 13 Mar 2009 06:00:06 AM
Hi,
I have a report which has 3 lists displayed in one page one below the other,so when the report is run all the data gets displayed in one page.When the output is exported to Excel 2002 data is getting displayed in one page of the excel but the requirement is,need to display 3 lists seperately in 3 pages i.e in 3 tabs of the excel
Could someone help with this?
Thanks
Title: Re: Exporting Report Output to EXCEL
Post by: billylodz on 13 Mar 2009 06:38:13 AM
page set for exel page output + ReportOutput() function
Title: Re: Exporting Report Output to EXCEL
Post by: Gollapudi on 13 Mar 2009 08:06:54 AM
Hi Billylodz,

Can you please be a bit detailed...

Thanks in Advance...
Gollapudi.
Title: Re: Exporting Report Output to EXCEL
Post by: Gollapudi on 13 Mar 2009 08:18:17 AM
Hi Midhl,

I just tried by putting them in separate pages, so Now im able to get them in separate tabs in Excel reports why dont you try the same.

Thanks,
Gollapudi.

Title: Re: Exporting Report Output to EXCEL
Post by: midhl on 13 Mar 2009 09:48:47 AM
Hi Gollapudi,
Thanks for our reply,I've already tried it,It works fine when they are created in 3 seperate pages but the issue is while running the report in HTML all the 3 lists i.e report output needs to be displayed in one single page
Title: Re: Exporting Report Output to EXCEL
Post by: billylodz on 13 Mar 2009 10:17:08 AM
can be done like that too, now just use ReportOutput() and Render variable for page  if ReportOutput()=HTML show firs page if Excel show other page.
Title: Re: Exporting Report Output to EXCEL
Post by: Gollapudi on 15 Mar 2009 04:36:45 AM
Hi Midhl,

Not an Issue, apart from these three pages create one more page, which will have all three lists on that page, and finally by using the ReportOutput() function you can do the conditiona formating create a vairiable like bellow.

Case
When ReportOutput()='HTML' then('Page1')
When ReportOutput() not like 'HTML' then('Page123')
end

And your values should be "Page1" and "Page123"
now go to page explorer and select page one in properties double click on render variable clear the check box for the value "Page123" and make sure that "Page1" is selected and then select the remaining pages and make sure that check box "Page123" for all pages and clear "Page1" for remaining.

This will defintely works...

Thanks,
Gollapudi.

Title: Re: Exporting Report Output to EXCEL
Post by: midhl on 15 Mar 2009 10:34:36 AM
Thanks gollapudi for the detailed explanation ,will work on it based on your explanation.
Title: Re: Exporting Report Output to EXCEL
Post by: midhl on 16 Mar 2009 03:20:33 AM
Hi Gollapudi,
I did try to create the report by creating a boolean variable by using the expression you gave and assigned to the report pages however it didn return any data.Also i did try to create a string variable using the same expression and the result is the same.The issue i see is page 1 and page 123 given in the expression i don think cognos is recognising them.
Also report pages need to have unique names hence 123 canot be given to all the pages other than page 1 right
Could you see any issues in my approach?
Thanks in advance
Title: Re: Exporting Report Output to EXCEL
Post by: Gollapudi on 16 Mar 2009 06:25:25 AM
Hi,

I have created sample report just check it out....

Thanks,
Gollapudi.
Title: Re: Exporting Report Output to EXCEL
Post by: midhl on 17 Mar 2009 02:48:27 AM
Thanks Gollapudi,its working.Thanks once again
Title: Re: Exporting Report Output to EXCEL
Post by: Gollapudi on 17 Mar 2009 03:24:06 AM
Your most Welcome!! ;D
Title: Re: Exporting Report Output to EXCEL
Post by: Abhicrn on 17 Mar 2009 08:40:36 AM
Good one thank you!!
Title: Re: Exporting Report Output to EXCEL
Post by: Gollapudi on 17 Mar 2009 08:42:17 AM
Great Welcome and its my pleasure.....!!