I want to open a html file in the text browser ,
and the code is as follows:

Qt Code:
  1. #include <QtGui>
  2. #include <QUrl>
  3. #include <QTextBrowser>
  4. int main(int argc, char **argv)
  5. {
  6. QApplication app( argc, argv );
  7. bw->setSource (QUrl("D:\\Wikipedia.html"));
  8. bw->setGeometry ( 100,100,400,400 );
  9. bw->show();
  10. return app.exec();
  11. }
To copy to clipboard, switch view to plain text mode 

QFSFileEngine:pen: No file name specified
QTextBrowser: Cannot open 'D:\Wikipedia.html' for reading
QTextBrowser: No document for D:\Wikipedia.html
But the browser is unable to open the file ...

What changes has to be made to identify the file and open it????