I am trying to open a pdf file with the default application through Qt's "DesktopServices" class.
But I am coming up with a ShellExecute
'file:///C:/PMPS/PMPSv1/Instuctionsforuse.pdf' failed (error 2). problem.
Here is my code:
#include <QDesktopServices>
#include <QUrl>
}
void Dialog::guideButtonClicked()
{
QDesktopServices::openUrl(QUrl("file:///C:/PMPS/PMPSv1/Instuctionsforuse.pdf"));
}