Yes, and even more: it will return additional information in other parameters of this method (where it happened and why)
int errorLine;
int errorColumn;
if (!doc.setContent(&file, true, &errorStr, &errorLine, &errorColumn))
{
//handling error here
file.close();
return false;
}
file.close();
QDomDocument doc;
QString errorStr;
int errorLine;
int errorColumn;
if (!doc.setContent(&file, true, &errorStr, &errorLine, &errorColumn))
{
//handling error here
file.close();
return false;
}
file.close();
To copy to clipboard, switch view to plain text mode
Bookmarks