Solved

Controlling Excel features over the web

Posted on 2003-12-05
5
302 Views
Last Modified: 2010-04-01
I have an intranet application in JSP deployed on Tomcat server. I am sending a HTML table to an Excel sheet using
<%@ page contentType="application/vnd.ms-excel" %>
(saw it on one of the exisitng ques in experts-exchange, thanks for that)
But I want some added functionality.
I want to control the page setup features. When the user opens the excel sheet he should get

Orientation automatically selected as Landscape.
Scaling fit to one window.
Margin left 0.00
Margin right 0.00

How Can this be done?
Plz help, i'll be extermely grateful.
0
Comment
Question by:feebie23
[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
  • 2
  • 2
5 Comments
 
LVL 15

Accepted Solution

by:
jimmack earned 190 total points
ID: 9887724
I don't think you can do this with the contentType setting.  That is just there to allow a quick and easy way to convert table data to a simple excel sheet.  If you want more control over the data, you'll need to use POI:

http://jakarta.apache.org/poi/
0
 
LVL 14

Assisted Solution

by:kennethxu
kennethxu earned 190 total points
ID: 9891977
jimmack is absolutely right.
Here is some additional information of how to set the print options:
http://jakarta.apache.org/poi/apidocs/org/apache/poi/hssf/usermodel/HSSFPrintSetup.html
let us know if you have further enquires.
0
 

Author Comment

by:feebie23
ID: 9894620
Thank You So Much
0
 

Author Comment

by:feebie23
ID: 9894626
You Guys are doing a great job
;)
0
 
LVL 15

Expert Comment

by:jimmack
ID: 9895041
;-)
0

Featured Post

Independent Software Vendors: 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

With the rising number of cyber attacks in recent years, keeping your personal data safe has become more important than ever. The tips outlined in this article will help you keep your identitfy safe.
Compliance and data security require steps be taken to prevent unauthorized users from copying data.  Here's one method to prevent data theft via USB drives (and writable optical media).
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

630 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