I think the problem is with the qrc file or the resource compiler.

I changed :

label->setPixmap(QPixmap(QString::fromUtf8(":/imagework/DSC00502.PNG")));

in the generated ui file to:

ui.label->setPixmap(QPixmap(QString::fromUtf8("D:\DSC00502. PNG")));

and used it in the constructor; and this worked. Why doesnt it work with the qrc file way ?