eclipse pywintypes.com_error

gurkan gurkanserin at gmail.com
Fri Dec 7 10:04:10 EST 2007


On 7 Aralık, 15:59, Tim Golden <m... at timgolden.me.uk> wrote:
> gurkan wrote:
> > i have treid the script :
>
> > #import active_directory
> > import win32com.client
>
> > win32com.client.Dispatch ("ADODB.Command")
> > #me = active_directory.find_user ()
>
> > #print me
>
> > again i got the error :
>
> > Traceback (most recent call last):
> >   File "H:\dev\eclipse\workspace\pyProject\src\pyPackage
> > \adDeneme3.py", line 4, in <module>
> >     win32com.client.Dispatch ("ADODB.Command")
> >   File "E:\Python25\Lib\site-packages\win32com\client\__init__.py",
> > line 95, in Dispatch
> >     dispatch, userName =
> > dynamic._GetGoodDispatchAndUserName(dispatch,userName,clsctx)
> >   File "E:\Python25\Lib\site-packages\win32com\client\dynamic.py",
> > line 98, in _GetGoodDispatchAndUserName
> >     return (_GetGoodDispatch(IDispatch, clsctx), userName)
> >   File "E:\Python25\Lib\site-packages\win32com\client\dynamic.py",
> > line 78, in _GetGoodDispatch
> >     IDispatch = pythoncom.CoCreateInstance(IDispatch, None, clsctx,
> > pythoncom.IID_IDispatch)
> > pywintypes.com_error: (-2147024770, 'The specified module could not be
> > found.', None, None)
>
> I don't think it's that the CoCreateInstance can't be found:
> that's a COM error you're seeing and it means that the
> IDispatch mechanism can't find the "ADODB.Command" you're
> looking for. If I get the chance I'll try to find a Vista
> machine to find out what the equivalent is. If anyone on
> the list has Vista and/or knows what the score is here,
> please let me know.
>
> To double-check, Gurkan, could you open the Registry and
> browse to HKEY_CLASSES_ROOT and look for a key ADODB.Command.
> I presume it's not present.
>
> TJG- Alıntıyı gizle -
>
> - Alıntıyı göster -

I checked the key,and it was found under HKEY_CLASSES_ROOT.And as i
mentioned before,
the problem happens only with eclipse and pydev,on the same machine i
can run the script from command line or with IDLE without any errors.



More information about the Python-list mailing list