Alex Denham wrote:
Hi,

Anybody happen to know how to go about creating a COM object that RegisterDragDrop() will actually accept?

print dropTarget
<COMObject Python.PyIDropTarget>

pythoncom.RegisterDragDrop(_id, dropTarget)

Traceback (most recent call last):
  File "C:\Python25\DragAndDrop.py", line 82, in <module>
    main()
  File "C:\Python25\DragAndDrop.py", line 41, in main
    pythoncom.RegisterDragDrop(_id, dropTarget)
ValueError: argument is not a COM object

Any help appreciated,

Thanks
Alex

How was your dropTarget object created ?
Normally, you'd create a class that implements the
methods of IDropTarget and either register it or
wrap it for local use using pythoncom.WrapObject.

It does look like PyIDropTarget is lacking docs, I'll
try to improve them.  Also, the other interface you'll
probably need (PyIDataObject) needs some
attention in the docs.

       Roger


_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32

Reply via email to