forum.vmspython.org Forum Index forum.vmspython.org
Forum system
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

VMS-Python and Excel (XLSX) files.

 
Post new topic   Reply to topic    forum.vmspython.org Forum Index -> Python for OpenVMS
View previous topic :: View next topic  
Author Message
jescab



Joined: 28 Jan 2008
Posts: 252

PostPosted: Fri Sep 29, 2017 1:53 pm    Post subject: VMS-Python and Excel (XLSX) files. Reply with quote

Hi!

We have a need to write Excel (.XLSX) files from our VMS system.
There are four tools (pyExcelerator, pyXLWriter, xlwt and xlutils) in the
current config. None of them supports .XLSX, as far I can see.

It seems as openpyxl is the most current tool for .XLSX support in Python.
I looked at the sources, and it was only .PY files (no .C or similar).
How hard is it to get this working in the current VMS-Python environment?

Regards, Jan-Erik Söderholm

EDIT: I should have added our environment:
Code:

$ python
Python 2.7.8 (default, Oct 31 2014, 14:12:12) [DECC] on OpenVMS
Type "help", "copyright", "credits" or "license" for more information.
>>>  Exit

$ tcpip sh ver

  HP TCP/IP Services for OpenVMS Alpha Version V5.7 - ECO 5
  on a COMPAQ AlphaServer DS20E 666 MHz running OpenVMS V8.4-2L2

$
Back to top
View user's profile Send private message
jescab



Joined: 28 Jan 2008
Posts: 252

PostPosted: Fri Sep 29, 2017 4:21 pm    Post subject: Reply with quote

I have tried to unzip the openpyxl files into python_root:[local] but I have "case" issues.

Unzip (5.11) says "creating: [.openpyxl-2_5_0a3]" but "$1$LDA2:[python278.local.OPENPYXL-2_5_0A3]"
is created and then all following files extractions fails with:

[ Cannot create output file [.openpyxl-2_5_0a3]AUTHORS.rst ]
[ %RMS-E-DNF, directory not found ]
[ %SYSTEM-W-NOSUCHFILE, no such file ]

Note, I have no idea if the package as such is case sensitive, I just guessed
so since some of the .PY files reads some other files using mixed case...

I can not find the option to UNZIP to preserve the case of file names created.
I have done "$ set proc/parse=ext/case=sens". Note also that i have very little
experience working with anything but the old ODS2 uppercase-only filenames... Smile

Jan-Erik.
Back to top
View user's profile Send private message
jescab



Joined: 28 Jan 2008
Posts: 252

PostPosted: Sat Sep 30, 2017 1:54 pm    Post subject: Reply with quote

Well, giving it a second thought, I guess xlwt would work just fine.
Any modern Excel can read the Excel .xls format. I also found a good tutorial:
http://github.com/python-excel/tutorial/raw/master/python-excel.pdf
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forum.vmspython.org Forum Index -> Python for OpenVMS All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group