Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

"Page Setup" orentation to LandScape

Posted on 2003-12-04
4
Medium Priority
?
276 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 3

Accepted Solution

by:
savalou earned 252 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 248 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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

One of the most important things in an application is the query performance. This article intends to give you good tips to improve the performance of your queries.
With so many activities to perform, Exchange administrators are always busy in organizations. If everything, including Exchange Servers, Outlook clients, and Office 365 accounts work without any issues, they can sit and relax. But unfortunately, it…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…

604 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