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
Solved

"Page Setup" orentation to LandScape

Posted on 2003-12-04
4
262 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

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Stuck in Bootstrap WysiHtml Editor 3 42
some methods private some are not 8 218
Best practices to work on a spring MVC project 1 126
maven webservice example issue 2 144
This article describes how to reset your Windows 10 password when you've forgotten it.
The advancement in technology has been a great source of betterment and empowerment for the human race, Nevertheless, this is not to say that technology doesn’t have any problems. We are bombarded with constant distractions, whether as an overload o…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

829 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