Programmer-Wanna-Be (Is Python for me?)
Geoff Talvola
gtalvola at nameconnector.com
Thu Oct 12 12:38:25 EDT 2000
Alex Martelli wrote:
> See, for example:
> http://msdn.microsoft.com/workshop/author/hta/overview/htaoverview.asp
> for one possibility, "HTML Applications" -- note that this page,
> authored by Microsoft, recommends that the GUI be an HTA "while the
> C++ or Visual Basic developers program the underlying functionality".
[snip]
> But Python (in the activescripting-compliant installation that
> comes with win32all) is perfectly able *and suited* to fulfill all
> of these roles -- it can perfectly well be the scripting language
> used within the page[s] of the HTA (<SCRIPT LANGUAGE="Python">...)
> as well as provide "the underlying functionality" (and, also,
> reusable components to be embedded within the page[s] {"behaviors",
> "scriptlets", &c}, nonpareil processing of any XML you might need
> or want to have, ...).
Interesting... I had never heard of an HTA before.
In playing around with HTA's, I immediately encountered a problem. The
following HTA page brings up the alert box twice, yet the JavaScript version
right after it correctly brings it up only once. Can you reproduce this?
<HEAD>
<SCRIPT LANGUAGE=Python>
def window_onload():
alert('window_onload was called!')
</SCRIPT>
</HEAD>
<HEAD>
<SCRIPT LANGUAGE=JSCRIPT>
function window.onload()
{
alert("window.onload was called!")
}
</SCRIPT>
</HEAD>
--
- Geoff Talvola
Parlance Corporation
gtalvola at NameConnector.com
More information about the Python-list
mailing list