def Flush(self, whatsthis=0): print "Flush" + str(whatsthis) fname = os.path.join(win32api.GetTempPath(), "persist.doc") open(fname, "wb").write(self.data) return S_OK