Converting a .xls file to .html

Tino Wildenhain tino at wildenhain.de
Wed Dec 3 08:57:06 EST 2008


Hi,


tarun wrote:
> Hello All,
>  
> I've a .xml file (saved as .xls) that can be opened in Microsoft excel. 

Well if its an xml file then just attach a style to it and you can
just view it in a browser w/o involving excel in the first place.

Also there are lots of xml libraries coming with python so you can 
translate it directly into HTML of your choice.

> I want to write python code that converts this excel file into .html (so 
> that it can be viewed as is in an explorer).

Whats an Explorer? I guess you mean Webbrowser here?

Now if you manage to have it in Excel, then you could just save
it as HTML (or whatever Microsoft believes is HTML).

If the file is stored elsewhere in Excel-Format, then
you could script that using xlrd (google for it)

Regards
Tino
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3241 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mail.python.org/pipermail/python-list/attachments/20081203/a32fa75f/attachment-0001.bin>


More information about the Python-list mailing list