[SOLVED] Writing XML with QDom



  • Hi All,

    I am able to write <Chapter Number =" 1"/>
    using the below code:

    @
    for (int x =0; x<10; x++)
    {
    QDomElement Chapter = doc.createElement("Chapter");
    Chapter.setAttribute( " Number ", " " + QString::number(x));
    Book.appendChild(Chapter);
    }

    @

    but how do I write " <Chapter> Number 1 </Chapter> "

    Thanks All


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.