"\pyrcc_main.py: File does not exist 'resources.qrc'" Code Answer's
You're definitely familiar with the best coding language Whatever that developers use to develop their projects and they get all their queries like "\pyrcc_main.py: File does not exist 'resources.qrc'" answered properly. Developers are finding an appropriate answer about \pyrcc_main.py: File does not exist 'resources.qrc' related to the Whatever coding language. By visiting this online portal developers get answers concerning Whatever codes question like \pyrcc_main.py: File does not exist 'resources.qrc'. Enter your desired code related query in the search bar and get every piece of information about Whatever code related question on \pyrcc_main.py: File does not exist 'resources.qrc'.
\pyrcc_main.py: File does not exist 'resources.qrc'
import sys, os, tempfile
import sip
sip.setapi('QString', 2)
from PyQt4 import QtCore
# from PyQt5 import QtCore
respath = os.path.abspath(sys.argv[1])
dirpath = os.path.dirname(respath)
sys.path.insert(0, dirpath)
import resources_rc
tmpdir = tempfile.mkdtemp(prefix='qrc_', dir=dirpath)
it = QtCore.QDirIterator(':', QtCore.QDirIterator.Subdirectories)
files = []
while it.hasNext():
uri = it.next()
path = uri.lstrip(':/')
if path.startswith('qt-project.org'):
continue
tmp = os.path.join(tmpdir, path)
if it.fileInfo().isDir():
try:
os.makedirs(tmp)
except OSError:
pass
else:
res = QtCore.QFile(uri)
res.open(QtCore.QIODevice.ReadOnly)
with open(tmp, 'wb') as stream:
stream.write(bytes(res.readAll()))
res.close()
files.append(' <file>%s</file>\n' % path.lstrip(':/'))
with open(os.path.join(tmpdir, 'resources.qrc'), 'w') as stream:
stream.write('<!DOCTYPE RCC><RCC version="1.0">\n')
stream.write('<qresource>\n%s</qresource>\n' % ''.join(files))
Source: stackoverflow.com
All those coders who are working on the Whatever based application and are stuck on \pyrcc_main.py: File does not exist 'resources.qrc' can get a collection of related answers to their query. Programmers need to enter their query on \pyrcc_main.py: File does not exist 'resources.qrc' related to Whatever code and they'll get their ambiguities clear immediately. On our webpage, there are tutorials about \pyrcc_main.py: File does not exist 'resources.qrc' for the programmers working on Whatever code while coding their module. Coders are also allowed to rectify already present answers of \pyrcc_main.py: File does not exist 'resources.qrc' while working on the Whatever language code. Developers can add up suggestions if they deem fit any other answer relating to "\pyrcc_main.py: File does not exist 'resources.qrc'". Visit this developer's friendly online web community, CodeProZone, and get your queries like \pyrcc_main.py: File does not exist 'resources.qrc' resolved professionally and stay updated to the latest Whatever updates.