Re: Get all attributes of a com object

2006-04-28 Thread eicwo01
Thanks for your tips.
But dir() and inspect did not really help.

dir():
['GetIDsOfNames', 'GetTypeInfo', 'GetTypeInfoCount', 'Invoke',
'InvokeTypes', 'QueryInterface', '_ApplyTypes_', '_FlagAsMethod',
'_LazyAddAttr_', '_NewEnum', '_Release_', '__AttrToID__',
'__LazyMap__', '__call__', '__cmp__', '__doc__', '__getattr__',
'__getitem__', '__init__', '__int__', '__len__', '__module__',
'__nonzero__', '__repr__', '__setattr__', '__setitem__', '__str__',
'_builtMethods_', '_enum_', '_find_dispatch_type_',
'_get_good_object_', '_get_good_single_object_', '_lazydata_',
'_make_method_', '_mapCachedItems_', '_oleobj_', '_olerepr_',
'_print_details_', '_proc_', '_unicode_to_string_', '_username_',
'_wrap_dispatch_']

pprint.pprint(inspect.getmembers(objDom)):
[('GetIDsOfNames',
  built-in method GetIDsOfNames of PyIDispatch object at 0x00AB7BFC),
 ('GetTypeInfo',
  built-in method GetTypeInfo of PyIDispatch object at 0x00AB7BFC),
 ('GetTypeInfoCount',
  built-in method GetTypeInfoCount of PyIDispatch object at
0x00AB7BFC),
 ('Invoke', built-in method Invoke of PyIDispatch object at
0x00AB7BFC),
 ('InvokeTypes',
  built-in method InvokeTypes of PyIDispatch object at 0x00AB7BFC),
 ('QueryInterface',
  bound method ADSIDispatch.QueryInterface of COMObject Dispatch
wrapper around PyIDispatch at 0xab7bfc with obj at 0x2625c8),
 ('_ApplyTypes_',
  bound method ADSIDispatch._ApplyTypes_ of COMObject Dispatch
wrapper around PyIDispatch at 0xab7bfc with obj at 0x2625c8),
 ...
Further more this nice method also did not know any more:
objDom._print_details_():

AxDispatch container Dispatch wrapper around PyIDispatch at 0xab7bfc
with obj at 0x2625c8
Methods:
Props:
Get Props:
Put Props:

Any additional hint  ?
Could it be, that you must know in advance, what to ask a com object;
so there is no dump possibility ?

Thanks
Wolfgang

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Get all attributes of a com object

2006-04-28 Thread eicwo01
Many thanks to all of you; I learned a lot and will come up next time
hopefully with some less utopic project ...
:-)

Wolfgang

-- 
http://mail.python.org/mailman/listinfo/python-list


Get all attributes of a com object

2006-04-27 Thread eicwo01
Without to know the names, is it possible to dump all attributes of a
com object?
from win32com.adsi import *
objDom = ADsOpenObject(LDAP:/ ...
print ???all attributes??? of objDom

Thanks
Wolfgang

-- 
http://mail.python.org/mailman/listinfo/python-list