When we use pyuic5 command to convert ui file created by qt designer, we may get this error:
Error: one input ui-file must be specified
In this tutorial, we will introduce you how to fix.
Look at converted command below:
pyuic5 -o C:\Users\fly165\Desktop\PDF Page Spliter\main_help.py C:\Users\fly165\Desktop\PDF Page Spliter\main_help.ui
Run this command, you will get this error:
Why does this error occur?
Because there exists some spaces in path.
For example:
C:\Users\fly165\Desktop\PDF Page Spliter\main_help.py
There are some spaces in string “PDF Page Spliter“.
How to fix this error?
It is easy to fix this error, change command to below:
pyuic5 -o "C:\Users\fly165\Desktop\PDF Page Spliter\main_help.py" "C:\Users\fly165\Desktop\PDF Page Spliter\main_help.ui"
Run this code, you will find ui file is converted successfully.