This series is a part of Club ShowMeDo. Click to learn why you should join our
club with a simple monthly subscription.
We teach Python and all the cool modules
Topics include beginner Python, GUIs, Web and Desktop Apps
Long, specially crafted video tutorials just for you
Club video tutorials extend our normal Free content
Save your time - we've done the research for you
Keep your skills up-to-date
Learn at your own pace, everything you need is shown to you
Over 12 hours of archived material are waiting for you in the club
 Ian Ozsvald
I am the co-founder of ShowMeDo (see http://showmedo.com/about), author of `The Screencasting Handbook <http://thescreencastinghandbook.com>`_ and the founder of the professional screencast production company `ProCasts <http://procasts.co.uk>`_:
.. image:: http://procasts.co.uk/media/procasts_sma ...
 Ian Ozsvald
I am the co-founder of ShowMeDo (see http://showmedo.com/about), author of `The Screencasting Handbook <http://thescreencastinghandbook.com>`_ and the founder of the professional screencast production ...
Our authors tell us that feedback from you is a big motivator. Please take a few moments to let them know what you think of their work.
# Notes for interacting with pyWin32 (http://sourceforge.net/projects/pywin32/)
# Running this script won't do much, instead just look at it for reference
# import the Dispatch library, get a reference to an Excel instance
from win32com.client import Dispatch
xlApp = Dispatch("Excel.Application")
# make Excel visible (1 is True, 0 is False)
# make a new Workbook
xlBook = xlApp.Workbooks.Add()
# get a reference to the same workbook - these two do the same thing
xlBook = xlApp.Workbooks(1)
# get a reference to the first sheet
xlSheet = xlBook.Sheets(1)
# reference a cell and set a value
# extract the value from a cell
a_value = xlSheet.Cells(1,1).Value
# empty cells have value of None
xlSheet.Cells(1,2).Value == None
# use formula as we would in excel
xlSheet.Cells(1,1).Value = "22"
xlSheet.Cells(1,2).Value = "=a1*2"
# change sheet's name
xlSheet.Name = "ian"
# INDEXING NOTE
xlSheet = xlBook.Sheets(1) # 1 based by default (but apparently can be changed)
xlSheet = xlBook.Sheets # 0 based as per Python
# book recommends using () and using the docs where necessary - usually 1 is first item
#links to a tutorial which links to the MS docs
#the above also have notes on 0/1 indexing
Are you learning Python? To keep the site running clean and ad-free we've started Club ShowMeDo. The club will allow you access to some special videos we're making to pass on programming skills we consider important to the development and enjoyment of Free Open Source Software (FOSS).
The focus at the moment is on developing with the Python programming language, one of the backbones of the FOSS movement with a huge number of included and third-party libraries.
We welcome feedback and we want to hear your ideas.
Showmedo's development is fairly rapid and bugs will inevitably creep in. If you have any problems please drop us a line using the contact address below. Likewise, any suggestions for improvements to the site are gratefully received.