RE: Excel, Struts and Downloading

2007-05-28 Thread Tahir Akhtar
OTH, if the stacktrace suggests the exception originates at the line containing response.setHeader/response.setContentType the problem might be upstream. In both cases the struts users list will be more helpful than poi. Regards, Tahir Akhtar > -Original Message- > From: Tahir

RE: Excel, Struts and Downloading

2007-05-28 Thread Tahir Akhtar
e you changed your action mappings during the upgrade? May be you can get some ideas from here http://wiki.apache.org/struts/StrutsFileDownload Regards, Tahir Akhtar > -Original Message- > From: Jon Wynacht [mailto:[EMAIL PROTECTED] > Sent: Monday, May 28, 2007 2:57 AM

RE: get cell number

2007-05-21 Thread Tahir Akhtar
Use org.apache.poi.hssf.util.CellReference. Simply create a new instance passing the string in the constructor then call getRow(), getCol(). > -Original Message- > From: Sebastian Frehmel [mailto:[EMAIL PROTECTED] > Sent: Monday, May 21, 2007 3:09 PM > To: poi-user@jakarta.apache.org > S

RE: Mail attachment

2007-05-14 Thread Tahir Akhtar
Adriana, It is tough to say anything about your problem without looking at the exception stack trace. For null pointer exception, it is crucial to know which reference was null (and this information can only be guessed by stacktrace) Regards, Tahir > -Original Message- > From: Adriana Roz

Printing all sheets of workbook

2007-05-08 Thread Tahir Akhtar
et name, all sheets print fine. Any help would be highly appreciated. Regards, Tahir Akhtar

RE: Please help - unknown grbit '16'

2007-04-25 Thread Tahir Akhtar
: http://www.cpearson.com/excel/array.htm http://www.ozgrid.com/Excel/arrays.htm [1] http://svn.apache.org/viewvc/jakarta/poi/trunk/src/java/org/apache/poi/hssf/ record/formula/ArrayPtg.java?view=markup [2] http://issues.apache.org/bugzilla/buglist.cgi?product=POI Regards, Tahir Akhtar

RE: Please help - unknown grbit '16'

2007-04-24 Thread Tahir Akhtar
It could be because of version incompatibility. May be user machine have upgraded to newer version of excel. Try opening the file in excel and save-as a new file paying attention to format (Excel 97 etc). Then try running your program on newly saved file. > -Original Message- > From: Sara

RE: Verifying Templates

2007-04-10 Thread Tahir Akhtar
I guess no. Are you talking about some Microsoft Excel specific templating system or general templating engines like velocity? Regards, Tahir Akhtar > -Original Message- > From: Tarek Nabil [mailto:[EMAIL PROTECTED] > Sent: Tuesday, April 10, 2007 4:34 PM >

RE: hi plsss help me out

2007-04-09 Thread Tahir Akhtar
The error basically says that the return type of HWPFDocument.file.getTextTable() is not String but you are trying to assign it to a String type variable. You must see the javadoc of TextPieceTable class to understand what is being returned by the method. > -Original Message- > From: Raje

RE: Excel Export

2007-03-15 Thread Tahir Akhtar
/octet-stream 2. Instead of letting Tomcat serve the file create a custom servlet and set HTTP headers manually like response.setContentType("application/octet-stream"); response.setHeader("Content-Disposition", "attachment; filename=report.xls&qu

RE: Can I set the active sheet of the workbook?

2007-03-12 Thread Tahir Akhtar
For setting a sheet's selected status (Helpful, for example, when you want the user to print only selected sheets): http://jakarta.apache.org/poi/apidocs/org/apache/poi/hssf/usermodel/HSSFShee t.html#setSelected(boolean) For setting the selected tab of workbook http://jakarta.apache.org/poi/apid

RE: Read Excel sheet after editing it inside the browser

2007-03-08 Thread Tahir Akhtar
Zep, I agree with Mike. Your solution will require * Excel installed on each client pc * Users must (temporarily) save the file on there PC * File will need to be uploaded. You may find browser security issues when trying to do local-save and upload behind the scenes (without user noticing temp

RE: HSSF Announcement: column autofit is implemented

2007-02-26 Thread Tahir Akhtar
Yegor, Thanks for implementing the much needed functionality. Is it possible to somehow auto-size only those columns that are not wide enough to display there content but leave those columns that are wider than required? I mean that I don't want to shrink the columns that can show there content

RE: HSSF:Plain background color filling

2007-02-19 Thread Tahir Akhtar
Try this, without setting the FillBackgroundColor // TURQUOISE "foreground", foreground being the fill foreground not the font color. style.setFillForegroundColor(HSSFColor.TURQUOISE.index); style.setFillPattern(HSSFCellStyle.SOLID_FOREGROUND); Wassalam Tahir > -Original Message-

RE: How to use POI (Newbie)

2007-01-26 Thread Tahir Akhtar
ServletOutputStream over FileOutputStream in this case? > [Tahir Akhtar] You cannot create a file at user's box. All you can do is to stream back the content through servlet stream with appropriate mime headers. User will see their browser's save/open dialog in this case. OTH you can

RE: Re[6]: Autosizing question:

2007-01-25 Thread Tahir Akhtar
BTW I have spotted a "Standard Font" option in MS Excel Tools-> Options [General Tab]. Changing this setting requires restarting excel. After changes take effect the default column widths are adjusted for new settings. So default font can be other than arial/12 Wassalam Tahir -Original Messag

RE: Re[4]: Autosizing question:

2007-01-25 Thread Tahir Akhtar
> I don't know. Arial is default and it is a proportional font and the glyphs have different > width. The phrase "1/256th of a character width of the default font" >is taken from the xls format spec. It says nothing about the >used characters. After doing a small experiment in excel, my guess is t

RE: Re[2]: Autosizing question:

2007-01-25 Thread Tahir Akhtar
I agree that the DPI issue is not relevant in auto-sizing context as it is only a rendering issue. For auto-sizing we only need font sizes for calculation purpose (we are not doing any rendering in Java). Now we have to see whether Andy was referring to same issue or something else. I would love i

RE: Autosizing question:

2007-01-25 Thread Tahir Akhtar
I guess the issue is not in the font sizes but the screen dpi calculation. Net result is if you render some text in "Ariel, 12" it will appear smaller on screen as compared to same text & font rendered by windows natively. See this bug report (and related bug 4016591) for details: http://bugs.sun.c

RE: How to use POI (Newbie)

2007-01-24 Thread Tahir Akhtar
Hi Rohilla 1. Its advisable to use the latest release poi-bin-3.0-alpha3-20061212. 2. There is nothing special about poi jars. Just use it as you use any java library i-e include it in your classpath(or out it in your WEB-INF/lib) and reference the classes via import statement or fully qualified c

RE: Autosizing question:

2007-01-24 Thread Tahir Akhtar
I am willing to contribute if you provide some initial pointers. Regards Tahir -Original Message- From: Avik Sengupta [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 24, 2007 6:08 PM To: poi-user@jakarta.apache.org Subject: Re: Autosizing question: >Since VBA have this function to a

RE: Autosizing question:

2007-01-24 Thread Tahir Akhtar
I am willing to contribute if you provide some initial pointers. Regards Tahir -Original Message- From: Avik Sengupta [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 24, 2007 6:08 PM To: poi-user@jakarta.apache.org Subject: Re: Autosizing question: >Since VBA have this function to a

RE: POI Source code carrying a virus

2007-01-24 Thread Tahir Akhtar
Happened to me too -Original Message- From: A. Rick Anderson [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 24, 2007 7:48 PM To: POI Users List Subject: POI Source code carrying a virus When I download the POI source code, my Symantec virus checker goes nuts. It reports that, at lea

RE: How to read single value from merged cells

2007-01-08 Thread Tahir Akhtar
for(int m=0;mmailto:[EMAIL PROTECTED] Sent: Monday, January 08, 2007 11:38 PM To: poi-user@jakarta.apache.org Subject: How to read single value from merged cells I haven't used POI in a long time, and I need to throw something together pretty quickly to read specific data out of a somew

RE: Slide Array---->.Jpg File

2006-11-08 Thread Tahir Akhtar
In my knowledge only feasible method of doing such stuff is through Open Office API. You will need a running instance of open office listening for requests. -Original Message- From: Nick Burch [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 08, 2006 8:08 PM To: POI Users List Subject

RE: Formulas with POI

2006-10-26 Thread Tahir Akhtar
Simplest way to go is to write the formula in the cell. When the user opens the workbook excel will calculate the values. IMO, formula evaluation support in POI 3.0 is for scenarios where you want to find out what value a formula cell will contain upon evaluation within you Java Application. Regar

RE: How to print excel files automatically

2006-09-12 Thread Tahir Akhtar
Another solution would be to add a macro to automatically call the print function of excel right after loading the excel file. But it will cause a lot of security warnings to user. -Original Message- From: Anthony Andrews [mailto:[EMAIL PROTECTED] Sent: Tuesday, September 12, 2006 6:53

RE: I want to talk with you about POI

2006-07-27 Thread Tahir Akhtar
Hi Bao, Sorry I was not able to write back to you earlier. I haven’t solved this problem yet but plan to do this with Jasper Report library. My solution will most likely revolve around a custom Jasper data source that will read from a POI work book object and expose data to Jasper Library. The tou

RE: Turn off warning in POI

2006-06-23 Thread Tahir Akhtar
class(PrecentPtg for example) how i can get to know which sid is free? by loking through all Ptg classes? What is the number of the bug with this attachment- http://issues.apache.org/bugzilla/attachment.cgi?id=17998 ? Tahir Akhtar wrote: >Well, I found your patch at > >http://issues.a

Can't get the percent PTG right

2006-06-22 Thread Tahir Akhtar
another patch to go with it. Regards, Tahir -Original Message- From: Tahir Akhtar [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 20, 2006 4:16 PM To: 'POI Users List' Subject: RE: Turn off warning in POI Well, I found your patch at http://issues.apache.org/bugzilla/attachment.cgi?id

RE: How To Get POI JAR With Patches

2006-06-21 Thread Tahir Akhtar
riginal Message- From: Nick Burch [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 21, 2006 3:07 PM To: POI Users List Subject: RE: How To Get POI JAR With Patches On Wed, 21 Jun 2006, Tahir Akhtar wrote: > I think Ramesh needs 2.5.1 branch with all the patches. I am interested > in this

RE: How To Get POI JAR With Patches

2006-06-21 Thread Tahir Akhtar
http://encore.torchbox.com/poi-svn-build/ builds against the svn HEAD and may not include patches submitted in bugzilla. I think Ramesh needs 2.5.1 branch with all the patches. I am interested in this too. Anyone? -Original Message- From: Erich W. Schasse [mailto:[EMAIL PROTECTED] Sent:

RE: Turn off warning in POI

2006-06-20 Thread Tahir Akhtar
Well, I found your patch at http://issues.apache.org/bugzilla/attachment.cgi?id=17998 Do you recommend using this patch with POI 2.5? -Original Message- From: Tahir Akhtar [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 20, 2006 4:12 PM To: 'POI Users List' Subject: RE: Turn o

RE: Turn off warning in POI

2006-06-20 Thread Tahir Akhtar
Daniel, I am using POI 2.5 release and I am generating workbooks based on user input. If my user provide a formula with % such as A3*10% it appears in excel as A3*10. The percent symbol is chopped off. Can I instruct POI to simply write the formula into the cell without trying to parse it? If no

RE: Getting the latest source

2006-06-15 Thread Tahir Akhtar
Tons of thanks. -Original Message- From: Nick Burch [mailto:[EMAIL PROTECTED] Sent: Thursday, June 15, 2006 8:32 PM To: POI Users List Subject: Re: Getting the latest source On Thu, 15 Jun 2006, Tahir Akhtar wrote: > I am having trouble checking-out poi from svn. Do we have nigh

Getting the latest source

2006-06-15 Thread Tahir Akhtar
Hi All, I am having trouble checking-out poi from svn. Do we have nightly snapshots somewhere? Thanks Tahir -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.394 / Virus Database: 268.8.4/364 - Release Date: 6/14/2006

RE: Phillip W Virgo/CIV/CSC is out of the office.

2006-05-10 Thread Tahir Akhtar
But I am against all things Viral, like viral marketing etc. And on top of that I cannot pronounce Epidemiology. Let the Myanh handle it alone ;) -Original Message- From: Phillip W Virgo [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 10, 2006 7:02 PM To: POI Users List Subject: Phillip W

RE: Major Problem With POI Excel reader: Urgent Help Needed

2006-05-08 Thread Tahir Akhtar
v/bin for latest development version. Development versions are work in progress while release is stable. _ From: Birendar Waldiya [mailto:[EMAIL PROTECTED] Sent: Monday, May 08, 2006 4:34 PM To: 'Tahir Akhtar'; poi-user@jakarta.apache.org Subject: RE: Major Problem With POI

RE: Major Problem With POI Excel reader: Urgent Help Needed

2006-05-08 Thread Tahir Akhtar
: Birendar Waldiya [mailto:[EMAIL PROTECTED] Sent: Monday, May 08, 2006 4:34 PM To: 'Tahir Akhtar'; poi-user@jakarta.apache.org Subject: RE: Major Problem With POI Excel reader: Urgent Help Needed Hi Tahir, I have done all the activities , the character on my eclipse console are print

RE: Major Problem With POI Excel reader: Urgent Help Needed

2006-05-08 Thread Tahir Akhtar
poi website which is 2.5.1. You can also get the latest development version from the dev directory. Both release and development versions are available in source and binary forms. Your problems seems to be related to handling of encoding. But I do not have anything to say about it :). Regards, Tahir

RE: Excel Export

2006-05-05 Thread Tahir Akhtar
I think you must try to get help in some weblogic related group as this issue is most probably not related to poi. Regards, Tahir Akhtar -Original Message- From: Prasanna Balaji [mailto:[EMAIL PROTECTED] Sent: Friday, May 05, 2006 5:07 PM To: 'POI Users List' Subject: RE: Ex

RE: Major Problem With POI Excel reader: Urgent Help Needed

2006-05-05 Thread Tahir Akhtar
nt version from the dev directory. Both release and development versions are available in source and binary forms. Your problems seems to be related to handling of encoding. But I do not have anything to say about it :). Regards, Tahir Akhtar -Original Message- From: [EMAIL PROTECTED] [mai

RE: Excel Export

2006-05-05 Thread Tahir Akhtar
Sorry, forgot to mention, you must have web developer extension installed. HYPERLINK "http://chrispederick.com/work/webdeveloper/"http://chrispederick.com/work/w ebdeveloper/ -Original Message----- From: Tahir Akhtar [mailto:[EMAIL PROTECTED] Sent: Friday, May 05, 2006

RE: Excel Export

2006-05-05 Thread Tahir Akhtar
.33 (Unix) mod_gzip/1.3.26.1a PHP/4.3.11 Vary: Host X-Powered-By: PHP/4.3.11 Content-Type: text/html Content-Encoding: gzip Content-Length: 3916 X-Cache: MISS from proxy.your-isp.net Connection: keep-alive 200 OK Regards, Tahir Akhtar -Original Message----- From: Tahir Akhtar [mailto:[EMAIL

RE: Excel Export

2006-05-05 Thread Tahir Akhtar
, browser is not getting proper headers in http response. It can be due to mal-functioning proxy among other things. Try different browsers to see if anyone get its right. Regards, Tahir Akhtar -Original Message- From: Prasanna Balaji [mailto:[EMAIL PROTECTED] Sent: Thursday, May 04, 2006 10

RE: Excel Export

2006-05-04 Thread Tahir Akhtar
Most probably issue is related to Content Type header. What happens if you write to a file on weblogic server with xls extension and open from there? If you can get it to work by writing to a file but not through servlet output stream, you need to check if web -Original Message- From: Pra

RE: InputStream and POIFSFileSystem...

2006-03-30 Thread Tahir Akhtar
from an input stream, attempting to read further data will return nothing. If your application is expecting certain amount of data (like a header in poifs) than it's going to crash with an exception. Hope that helps. Regards, Tahir Akhtar -Original Message- From: Sawant, Ramdas (IT) [m

RE: Why Excel file size increases after saving it through POI?

2006-03-30 Thread Tahir Akhtar
Could be due to cell styles. You may be creating different style objects for each formatted cell even though there style is same. Just a guess :) -Original Message- From: Goswami, Sachin (IT) [mailto:[EMAIL PROTECTED] Sent: Thursday, March 30, 2006 6:39 PM To: poi-user@jakarta.apache.org

RE: read unique values from the excel column

2006-03-22 Thread Tahir Akhtar
will work: Loop over the rows -Put the value of the column in a set You will have to put value objects not the complete HSSFCell object. Rest is upto the equals method implementation of values :) Regards, Tahir Akhtar -Original Message- From: Sawant, Ramdas (IT) [mailto:[EMAIL

RE: HSSFFormulaEvaluator missing

2006-03-13 Thread Tahir Akhtar
Go to download * poi/dev/bin/poi-bin-3.0-alpha1-20050704.tar.gz * extract the jar files from archive including the poi-scratchpad-3.0-alpha1-.. Regards, Tahir Akhtar -Original Message- From: Tahir Akhtar [mailto:[EMAIL PROTECTED] Sent: Monday, March 13, 2006 1:46 PM To: 'POI

RE: HSSFFormulaEvaluator missing

2006-03-13 Thread Tahir Akhtar
>From http://jakarta.apache.org/poi/hssf/eval.html: "This code currently lives the scratchpad area of the POI CVS repository. Ensure that you have the scratchpad jar or the scratchpad build area in your classpath before experimenting with this code." I am not sure about how to get scratchpad jar.

Reading by Cell Address or Range

2006-03-09 Thread Tahir Akhtar
Hi, How can I get a cell from HSSFSheet with a cell address in excel notation like A10 or a collection of cells by specifying a range like A1:A10. Is it possible? Regards, Tahir -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.375 / Virus Database: 268.2.1

RE: Excel Sheet Title

2006-03-09 Thread Tahir Akhtar
l"); > response.setHeader("Content-Disposition", "attachment; filename=" + > filename); > > But not IE. IE just show the servlet name as before. > > Thanks again. > > Jody > > > > > > "Tahir Akhtar" <[EMAIL PROTECTED]> >

RE: [NEW] - RE: Excel Sheet Title - Message is from an unknown sender

2006-03-08 Thread Tahir Akhtar
Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 08, 2006 10:28 AM To: POI Users List Subject: [NEW] - RE: Excel Sheet Title - Message is from an unknown sender That didn't do it either but thanks for trying. Jody "Tahir Akhtar" <[EMAIL PR

RE: Excel Sheet Title

2006-03-08 Thread Tahir Akhtar
. If I use: response.setContentType("application/vnd.ms-excel"); response.setHeader("Content-Disposition", "attachment; filename=" + filename); I get a view dialog but the header doesn't take in I.E. Maybe I will not be able to do this? Jody "Tahir

RE: Excel Sheet Title

2006-03-08 Thread Tahir Akhtar
; But not IE. IE just show the servlet name as before. Thanks again. Jody "Tahir Akhtar" <[EMAIL PROTECTED]> 03/08/2006 10:04 AM Please respond to "POI Users List" To "'POI Users List'" cc Subject RE: Excel Sheet Title Jody, You ne

RE: POI to PDF

2006-03-08 Thread Tahir Akhtar
t; Subject: Re: POI to PDF >> >> Well you can't export to PDF from POI you need to load the file into >> e.g. OpenOffice using UNO and let OO do the Job for you. How this can be >> done is shown in the codesnippet here: >> >> http://codesnippets.services.ope

RE: POI to PDF

2006-03-08 Thread Tahir Akhtar
Well you can't export to PDF from POI you need to load the file into e.g. OpenOffice using UNO and let OO do the Job for you. How this can be done is shown in the codesnippet here: http://codesnippets.services.openoffice.org/Office/Office.ConvertDocuments.s nip Tom Tahir Akhtar wrote:

RE: Excel Sheet Title

2006-03-08 Thread Tahir Akhtar
Jody, You need to set content-disposition header // Set the headers. res.setContentType("application/x-download"); res.setHeader("Content-Disposition", "attachment; filename=" + filename); For more details see http://www.onjava.com/pub/a/onjava/excerpt/jebp_3/index3.html Hope this helps. Regard

POI to PDF

2006-03-07 Thread Tahir Akhtar
Hi, If I generate an excel sheet using POI, and have an instance of HSSFWorkbook on hand, what are my options for generating a PDF file? Any ideas will be really helpful. Regards, Tahir -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.375 / Virus

POI Formula Evaluation status?

2006-03-07 Thread Tahir Akhtar
Hi, The POI Formula evaluation page [http://jakarta.apache.org/poi/hssf/eval.html] says: >This code currently lives the scratchpad area of the POI CVS repository. >Ensure that you have the scratchpad jar or the scratchpad build area in your classpath before experimenting with this code. *

Using POI FormulaParser class

2006-03-07 Thread Tahir Akhtar
Hi, I am trying to use FormulaParser class to parse excel formula. I understand following constructor can be used for parsing formulas. HYPERLINK "http://jakarta.apache.org/poi/apidocs/org/apache/poi/hssf/model/FormulaPars er.html#FormulaParser(java.lang.String, org.apache.poi.hssf.model.Workb

Using POI FormulaParser class

2006-03-07 Thread Tahir Akhtar
Hi, I am trying to use FormulaParser class to parse excel formula. I understand following constructor can be used for parsing formulas. HYPERLINK "http://jakarta.apache.org/poi/apidocs/org/apache/poi/hssf/model/FormulaPars er.html#FormulaParser(java.lang.String, org.apache.poi.hssf.model.Workb