I'm almost disappointed that so many people think this is an impressive new thing.
Another reason you should learn to code: Python for Excel
11–20 of 32 posts
Re: Another reason you should learn to code: Python for Excel
#12Two articles on HN, yet still no answer to "How is this better than using Python and Excel with COM?" I'm almost disappointed that so many people think this is an impressive new thing.
Re: Another reason you should learn to code: Python for Excel
#13Re: Another reason you should learn to code: Python for Excel
#14If you use Excel and want to take it a bit further I would suggest that RExcel is probably a better choice. The R environment has abundant, relevant functionality for those who use Excel frequently.
When I encountered tasks that were tedious in Excel or beyond the abilities of Excel I went searching for a solution. After looking at VBA I eventually tried RExcel. I barely used RExcel as I found it more convenient to work in R itself. Now I use R and a database via ODBC far more than I use Excel. I can see using R as a gateway to other programming languages.
Re: Another reason you should learn to code: Python for Excel
#15Here's a shortlist:
- VBA is case-insensitive. If you don't know the significance of this, you've never taught beginners - VBA hides event binding and namespaces for the user. Major obstacles removed - VBA has full autocomplete - VBA has F1 context-sensitive help - VBA automatically formats and indents your code - VBA is more verbose, and verbosity aids comprehension - VBA finishes most of what you type, so you don't actually have to type much more than in Python - VBA was designed for Excel, and vice versa. The object models fit - There's tons of online resources for using VBA in Excel
And finally, VBA is dead-easy to learn, even for Microsoft-hating open source hackers. You just have to learn to get over yourself.
Re: Another reason you should learn to code: Python for Excel
#16It lets you write Excel addins in Python in a very straightforward way. Python functions can implement functions, menu items, macros. Supports asynchronous functions in the latest Excel.
See examples here: http://pyxll.com/introduction.html
Re: Another reason you should learn to code: Python for Excel
#17Two articles on HN, yet still no answer to "How is this better than using Python and Excel with COM?" I'm almost disappointed that so many people think this is an impressive new thing.
No instantiating a COM object, no opening a workbook, no selecting a worksheet, etc.
Re: Another reason you should learn to code: Python for Excel
#18VBA is one of the best languages and environments for beginners ever. Why using Python instead would give the beginner anything, is beyond me. Here's a shortlist: - VBA is case-insensitive. If you don't know the significance of this, you've never taught beginners - VBA hides event binding and namespaces for the user. Major obstacles removed - VBA has full autocomplete - VBA has F1 context-sensitive help - VBA automat…
Actually it depends, if those beginners are supposed to become programmers then you're wrong, if they just want to write one piece of software once in their life and never do it again then maybe you're right.
Re: Another reason you should learn to code: Python for Excel
#19This post talks about switching from (VB to Python). That only happening after they've learned to code.
Re: Another reason you should learn to code: Python for Excel
#20This is about people switching from (VB to Python), which is only happening after they've learned to code.