L
L
lessstreng2019-07-04 15:47:47
Python
lessstreng, 2019-07-04 15:47:47

Does the function create docx only after the program is closed?

The wxpython button calls a function that creates, in theory, a docx document. For some reason, the document is created only after the frame is closed and only one, even if the button is pressed several times. Please help me fix it.

Btn_On_Assistent = wx.Button(self, -1)
        self.Bind(wx.EVT_BUTTON, self.makeSomething, Btn_On_Assistent)

def makeSomething():
        NewDocument = Document()
        NewDocument.save('test.doc')

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question