How to read multiple XML using QML?



  • Hello all,

    I have 2 xml file "EmployList.xml" and "Employ<Name>.xml". I wrote a program to read salary of employ which is present into Employ<name>.xml using xmlListModel in QML. But now i want salary of all employ. So in this case I have to get Employ name from EmployList.xml and using that Employ name read that particular Employ<name>.xml to get salary.

    So please help me for same,

    Thank you.

    EmployList.xml :
    <employ_List>
    <employname>N1</employname>
    <employname>N2</employname>
    <employname>N3</employname>
    <employname>N4</employname>
    <employname>N5</employname>
    <employname>N6</employname>
    </employ_List>

    Employ<name>.xml :::: EmployN1.xml
    <detail>
    <employ id="2"/>
    <salary>1000</salary>
    </detail>

    //Note : I have Multiple xml file like EmployN1.xml, ....N2.xml etc.

    OutPut :
    N1 : 1000
    N2 : 2000
    N1 = 1000


Log in to reply
 

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