ADO example code failed:hlp!

Mark Hammond MHammond at skippinet.com.au
Thu Aug 5 18:45:22 EDT 1999


Hoon Yoon wrote in message <37A9F366.EA01D915 at bigfoot.com>...
>Running Christian's code, I get following error message. What am I doing
>wrong? It's same code, but the constants do not contain adModeReadWrite.
>Pls help!
>Thanks much in Adv,

Most likely you have not run "makepy" over the ADO library.

Try:

>import win32com.client
>db=win32com.client.Dispatch("ADODB.Connection")

print db

If it says "COM object <ADODB.Connection>", you have not used makepy.  If it
says "win32com.gen_py.blah..." then it is a different problem.

To run makepy, select it from the Pythonwin tools menu, or double-click on
"Python\win32com\client\makepy.py"

Mark.







More information about the Python-list mailing list