Boron
16th February 2010, 14:58
Hello,
I just wanted to to "start" a html file, expecting it to be displayed in the standard browser (Firefox in my case; may be Internet Explorer or anything else on other systems; my application is restricted to Windows systems for other reasons):
QString command(QCoreApplication::applicationDirPath() + "/Help/index.html" );
bool success = QProcess::startDetached( command );
The html file is in the subdirectory "Help" that lies parallel to the executable.
On Windows systems "starting" a file of any type normally starts the application that is linked to the file extension.
When trying to use this behaviour with a QProcess it doesn't seem to work.
Any ideas how I can open a file in its "standard application"?
I just wanted to to "start" a html file, expecting it to be displayed in the standard browser (Firefox in my case; may be Internet Explorer or anything else on other systems; my application is restricted to Windows systems for other reasons):
QString command(QCoreApplication::applicationDirPath() + "/Help/index.html" );
bool success = QProcess::startDetached( command );
The html file is in the subdirectory "Help" that lies parallel to the executable.
On Windows systems "starting" a file of any type normally starts the application that is linked to the file extension.
When trying to use this behaviour with a QProcess it doesn't seem to work.
Any ideas how I can open a file in its "standard application"?