ScriptControl (was Re: Can Python replace Visual Basic? Should it?...and generalities : ))

Alex Martelli aleaxit at yahoo.com
Wed Mar 7 05:36:03 EST 2001


"Brad Bollenbach" <bbollenbach at homenospam.com> wrote in message
news:2Ybp6.12845$hn5.1818206 at news1.rdc1.mb.home.com...
> This reply is interesting, but still contains a lot of the "I've started
> invistigating Python and these are the things I like about it" comments,
> which I was hoping to avoid.
>
> [snip]
>
> >   A Python "OCX" control needs to be written.  This control
> >   would simply encapsulate Python for us Visual Basic idiots.
> >   This way we could 'pop in the control in our VB project and
> >   start using Python for parts of the program.
>
> That's a neat idea. I hope someone smarter than me decides to do it. :)

Microsoft has done it!-)

They cleverly call it the ScriptControl, so it won't be immediately
obvious that its real purpose is to let you embed Python in your VB
programs without breaking a sweat; and, accordingly, you have to
explicitly set its Language property to "Python" (but that, no
doubt, is in pursuance of Python's "explicit is better than implicit"
philosophy -- bet you never expected THAT one from MS, hm?-).

You also have to have the ActiveState build of Python installed
(or, install the standard build, then go to ActiveState anyway
to pick up the win32all extensions and install those on top of
the standard Python distribution).


> As, you mentioned in a reply to the other thread of this thread (heh),
> coding really is the most insignificant part of a large programming
project
> in a coporate environment. In theory at least, you should have a clear
idea
> of what you're going to do before you do it, in which case the coding
> (almost irregardless of the language) is often times just grunt work.

The *maintenance* part of the program's lifetime costs is paramount,
and that involves LOTS of fiddling with code too -- therefore, the
claim that "coding ... is insignificant" (while not absurd if only
applied to the INITIAL coding) is quite misleading.  That code will
have to be read/understood/fixed/modified a thousand times...!


Alex






More information about the Python-list mailing list