Hello,

I need to work with web generated xml document. If I work with local disk file, everithing's fine:
Qt Code:
  1. ...
  2. QFile file(url);
  3. if(!file.open(QFile::ReadOnly | QFile::Text)) {
  4. cout << "chyba!";
  5. return;
  6. }else{
  7. cout << "soubor otevren...";
  8. read(&file);
  9. }
  10. file.close();
  11. ...
To copy to clipboard, switch view to plain text mode 

You see, I send to method read pointer to file (QIODevice). I want to do something like this:
Qt Code:
  1. ...
  2. QUrl address = QUrl(url);
  3.  
  4. if(!address.open(QFile::ReadOnly | QFile::Text)) {
  5. cout << "chyba!";
  6. return;
  7. }else{
  8. cout << "soubor otevren...";
  9. read(&address);
  10. }
  11. ...
To copy to clipboard, switch view to plain text mode 
Of course I know, it's wrong. I found only QDesktopServices:penUrl ( const QUrl & url ) but it opens URL in web browser and I don't want this! I need to work with generated xml file.

It crossed my mind that I can save generated document to disk and then can I work with that like I want to. But I think it's soo complicated.

Thx for any answer...