Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from PyQt5 import QtWidgets, uic
- import sys, os, PyPDF2
- uicFile = 'mainUi.ui'
- path = f'{os.path.dirname(os.path.abspath(__file__))}\\{uicFile}'
- class Ui(QtWidgets.QMainWindow):
- def __init__(self):
- super(Ui, self).__init__() # Call the inherited classes __init__ method
- uic.loadUi(path, self) # Load the .ui file
- class Documents(self, file):
- @staticmethod
- def documentsPages():
- doc_pages = {}
- fields = {
- 'schedule':'Schedule',
- 'miof':'MI OForm',
- 'gsc':'GSC',
- 'smokeco':'Smoke Test',
- 'eicr':'EICR',
- 'featic':'FEAT & IC',
- 'past':'Past'
- }
- for k, v in fields:
- start_page = f'Ui.{k}SpinMin'
- doc_pages[v] = {'startPage':}
- if __name__ == '__main__':
- app = QtWidgets.QApplication(sys.argv) # Create an instance of QtWidgets.QApplication
- window = Ui() # Create an instance of our class
- window.show() # Show the GUI
- app.exec_() # Start the application
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement