Solved

"Page Setup" orentation to LandScape

Posted on 2003-12-04
4
259 Views
Last Modified: 2008-02-01
Hi
I have generated a report using JSP,and there are two buttons in that page
1, "Export to Excel" what it does is It Export the Report Data to Excel Format.
2, "Print" What it does is It format the report page by removing the Button etc.
now the Problem is client wants the "Page Setup" orentation to LandScape as default instead of (Potrait) for both the 2 pages(Export to Excel and Print).

any Idea how to do this through JSP.

Thanks
Naveeth
0
Comment
Question by:naveeth
4 Comments
 
LVL 3

Accepted Solution

by:
savalou earned 63 total points
ID: 9874523
People keep asking this question.  There's no way to even print with java/jsp code, first of all.  You'd have to use javascript in the final html document.  Secondly, even with javascript all you can do is bring up the print dialog, no more.  Tweaking with printer settings gets into platform/browser dependent issues and the javascript/css/html standards don't address it. You could probably do something in IE (you could probably reformat your disk in IE) but you'd have search and re-search the msdn site and you still wouldn't find any useful info.

0
 
LVL 14

Assisted Solution

by:kennethxu
kennethxu earned 62 total points
ID: 9874881
savalou is right that you cannot do this with javascript/css/html.

1. POI generates real excel document, I cannot be sure but you might have chance to page orentation with it. http://jakarta.apache.org/poi/

2. I used xsl-fo with FOP to generate pdf file, that for sure you can preset the orentation. http://xml.apache.org/fop/
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article lists the top 5 free OST to PST Converter Tools. These tools save a lot of time for users when they want to convert OST to PST after their exchange server is no longer available or some other critical issue with exchange server or impor…
Note: This is the second blog post in a series on email clearinghouses (https://www.xmatters.com/alert-management/blog-email-has-failed-us?utm_campaign=70138000000ydLoAAI&utm_source=exex&utm_medium=article&utm_content=blog-post).   Every month t…
Hi friends,  in this video  I'll show you how new windows 10 user can learn the using of windows 10. Thank you.
As a trusted technology advisor to your customers you are likely getting the daily question of, ‘should I put this in the cloud?’ As customer demands for cloud services increases, companies will see a shift from traditional buying patterns to new…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now