Wednesday, 10 October 2012

function in Python to print all the current properties and values of an object



#useful in mapi object on outlook for eg

def dump(obj):
  for attr in dir(obj):
    print "obj.%s = %s" % (attr, getattr(obj, attr))

No comments:

Post a Comment