The name which will appear in the ui_*.h file is the object name given to the object in the Designer by you. Therefore open the sortDialog.ui file and check (and remember) object names given to your objects. You will need them later in your code. The object name of the main dialog window is not sortDialog but Dialog. The compiler searched Ui::sortDialog and failed.