Nominate our 2022 Qt Champions!

Filtering XmlListModel data

  • Hi,
    I have a xml file.

    <field name="esname">Dancing ceremony</field>
    <field name="esbegin">2000-11-22</field>
    <field name="esend">2012-10-17</field>
    <field name="eventid">1829275</field>
    <field name="eventname">ASASASASASASAS</field>
    <field name="eventdate">2012-04-31</field>
    <field name="eventtime">19:00:00</field>
    The xml file contains number of rows that contain different events on different dates.

    Assume today is 2012-04-22. Then 2012-04-31(<field name="eventdate">2012-04-31</field>) is on next week. I want to filter the
    event name (<field name="esname">Dancing ceremony</field>) where date belongs to next week.

    Filter events where eventdate belong to current date/ current week

    When current date is 2012-04-31, I want to filter the events belongs

    is there a way to filter this XmlListModel in QML?

    It would be great help.
    Thank you

    [Edit: Added @ tags; mlong]

Log in to reply