def Record(name, object):
 import gencache
 object = gencache.EnsureDispatch(object)
 module = sys.modules[object.__class__.__module__]
 package = gencache.GetModuleForTypelib(module.CLSID, module.LCID, module.MajorVersion, module.MinorVersion)
 try:
  struct_guid = package.RecordMap[name]
 except KeyError:
  raise ValueError(("The structure '%s' is not defined in module '%s'" % (name, package)))
 return pythoncom.GetRecordFromGuids(module.CLSID, module.MajorVersion, module.MinorVersion, module.LCID, struct_guid)

def Record ( name , object ) : import gencache object = gencache . EnsureDispatch ( object ) module = sys . modules [ object . __class__ . __module__ ] package = gencache . GetModuleForTypelib ( module . CLSID , module . LCID , module . MajorVersion , module . MinorVersion ) try : struct_guid = package . RecordMap [ name ] except KeyError : raise ValueError ( ( "The structure '%s' is not defined in module '%s'" % ( name , package ) ) ) return pythoncom . GetRecordFromGuids ( module . CLSID , module . MajorVersion , module . MinorVersion , module . LCID , struct_guid )
creates a new record object .