title: pyQt: How do I update a label?
body: <p>I created this simple UI with qtDesigner and I want to update my label every 10 seconds with the value of a function, but I have no idea how to do this.I've tried different things but nothing worked.</p>
  
  <pre><code>def example():
      ...
      return text
  </code></pre>
  
  <p>UI:</p>
  
  <pre><code>class Ui_Form(object):
      def setupUi(self, Form):
          Form.setObjectName("Form")
          Form.resize(400, 300)
          self.label = QtWidgets.QLabel(Form)
          self.label.setGeometry(QtCore.QRect(165, 125, 61, 16))
          self.label.setObjectName("label")
  
          self.retranslateUi(Form)
          QtCore.QMetaObject.connectSlotsByName(Form)
  
      def retranslateUi(self, Form):
          _translate = QtCore.QCoreApplication.translate
          Form.setWindowTitle(_translate("Form", "Form"))
          self.label.setText(_translate("Form", plsupdatethis)
  
  if __name__ == "__main__":
      import sys
      app = QtWidgets.QApplication(sys.argv)
      Form = QtWidgets.QWidget()
      ui = Ui_Form()
      ui.setupUi(Form)
      Form.show()
      sys.exit(app.exec_())
  </code></pre>