Blazur
Blazur

Reputation: 13

Qt png images not showing up in deployment app

My .png images show up im Qt Creator and also when i build my project in both debug and release situations. When I try to deploy my exe and run it my images don't show up.

My .pro file:

QT       += core gui multimedia multimediawidgets

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

TARGET = WinSim
TEMPLATE = app

DEFINES += QT_DEPRECATED_WARNINGS


SOURCES += main.cpp\
    mainwindow.cpp

HEADERS  += mainwindow.h

FORMS    += mainwindow.ui


RESOURCES += \
resourcefile.qrc
win32:RC_ICONS += icons\uokicon.ico

My resource file:

<RCC>
<qresource prefix="/">
    <file>icons/ico.png</file>
    <file>icons/ppicon.png</file>
    <file>icons/cricon.png</file>
    <file>icons/bgim.png</file>
    <file>icons/button.png</file>
    <file>icons/startmenu.png</file>
    <file>icons/power.png</file>
    <file>icons/uokicon.ico</file>
</qresource>
</RCC>

Upvotes: 0

Views: 829

Answers (1)

Blazur
Blazur

Reputation: 13

All i needed to do was deploy my program with windeployqt. Thank you @eyllanesc for pointing that out !

Upvotes: 1

Related Questions