parsing an Excel formula with the re module

John Machin sjmachin at lexicon.net
Tue Jan 12 07:35:57 EST 2010


On 12/01/2010 6:26 PM, Chris Withers wrote:
> John Machin wrote:
>> The xlwt package (of which I am the maintainer) has a lexer and parser
>> for a largish subset of the syntax ... see  
>> http://pypi.python.org/pypi/xlwt
> 
> xlrd, no?

A facility in xlrd to decompile Excel formula bytecode into a text 
formula is currently *under discussion*.

The OP was planning to dig the formula text out using COM then parse the 
formula text looking for cell references and appeared to have a rather 
simplistic view of the ease of parsing Excel formula text -- that's why 
I pointed him at those facilities (existing, released, proven in the 
field) in xlwt.






More information about the Python-list mailing list