Win32com ADO curiosity #1: MoveNext

Alex Martelli alex at magenta.com
Fri Jul 7 04:57:31 EDT 2000


Bill Tutt <billtut at microsoft.com> wrote in message
news:4D0A23B3F74DD111ACCD00805F31D8101D8BD280 at RED-MSG-50...
> Because this is Python, and not VB or VBScript.
> It's a language syntax thing.
    [snip]
> From: mksql at my-deja.com [mailto:mksql at my-deja.com]
> Sent: Thursday, July 06, 2000 1:21 PM
    [snip]
> Why does MoveNext require the () ? The ADO object model does not
> specify parameters for MoveNext, MoveFirst, etc.

Exactly.  In Python, like in C or C++, just mentioning a
function's name does not *call* it; you have to append
empty parentheses to tell the language that you want to
call the function without parameters.  (Just mentioning
it without parens yields its address in C or C++, the
function-object itself in Python, but that is by the by).

No object model (ADO or other) gets to change the language
from which it is used (C++, Python, or other).


Alex






More information about the Python-list mailing list