You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@poi.apache.org by Cl...@akerkvaerner.com on 2004/07/08 18:18:51 UTC

Formulas contained in a spreadsheet Add-In


Anybody know how to write, to a cell, a formula that is contained in a Excel spreadsheet add-in?

I have tried cell.setCellFormula(formulaString), but this writes the formula to the cell incorrectly.

For example:
	cell.setFormula("DirExists(A7)") gets written to the cell as =A7()?DIREXISTS, which obviously does not work.

I have had a squint through the POI javadoc but can't see anything.
Any help would be very welcome.

Thanks
Clive Janes

This e-mail and any attachment are confidential and may be privileged or otherwise protected from disclosure. It is solely intended for the person(s) named above. If you are not the intended recipient, any reading, use, disclosure, copying or distribution of all or parts of this e-mail or associated attachments is strictly prohibited. If you are not an intended recipient, please notify the sender immediately by replying to this message or by telephone and delete this e-mail and any attachments permanently from your system.

---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: poi-user-help@jakarta.apache.org


Re: Formulas contained in a spreadsheet Add-In

Posted by Avik Sengupta <av...@itellix.com>.
Where do you get the string "=A7()?DIREXISTS" ?? If it is from one of
POI's viewers, then well, actually that is how formulas are stored in
xls files, in Reverse Polish Notation. However, if this is how you see
it in excel, its obviously wrong.  I believe user defined functions in
the workbook should work, but dunno about add in functions.  

Not saying your bug report is necessarily wrong, but cant understand
it.. you need to be clearer in what you are doing and what you are
seeing... 

On Thu, 2004-07-08 at 21:48, Clive.Janes@akerkvaerner.com wrote:
> Anybody know how to write, to a cell, a formula that is contained in a Excel spreadsheet add-in?
> 
> I have tried cell.setCellFormula(formulaString), but this writes the formula to the cell incorrectly.
> 
> For example:
> 	cell.setFormula("DirExists(A7)") gets written to the cell as =A7()?DIREXISTS, which obviously does not work.
> 
> I have had a squint through the POI javadoc but can't see anything.
> Any help would be very welcome.
> 
> Thanks
> Clive Janes
> 
> This e-mail and any attachment are confidential and may be privileged or otherwise protected from disclosure. It is solely intended for the person(s) named above. If you are not the intended recipient, any reading, use, disclosure, copying or distribution of all or parts of this e-mail or associated attachments is strictly prohibited. If you are not an intended recipient, please notify the sender immediately by replying to this message or by telephone and delete this e-mail and any attachments permanently from your system.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: poi-user-help@jakarta.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: poi-user-help@jakarta.apache.org