0

I need to parse below xml file in black berry

<Vehicles> 
    <Car> 
        <ID>000001</ID> 
        <Make>Audi</Make> 
    </Car> 
    <Car> 
        <ID>000002</ID> 
        <Make>Buick</Make> 
    </Car> 
    <Car> 
        <ID>000015</ID> 
        <Make>Chevrolet</Make> 
    </Car> 
    <Car> 
        <ID>000003</ID> 
        <Make>Chrysler</Make> 
    </Car>  
</Vehicles> 

Can any one pleae tell me how to parse it.

Swati
  • 2,870
  • 7
  • 45
  • 87
Kotibab
  • 85
  • 1
  • 1
  • 7

2 Answers2

2

Please look into the following posts in stackoverflow.com

Parse XML file on BlackBerry

BlackBerry/J2ME - SAX parse collection of objects with attributes

Note: Please search in stackoverflow.com before post an issue.

Community
  • 1
  • 1
Jomy John
  • 6,308
  • 4
  • 28
  • 32
0

As a starting point check the "xmldemo" sample app. It is a part of the BB SDK placed on your PC. XMLDemoScreen has an example of a DOM-parser implementaion.

Vit Khudenko
  • 28,288
  • 10
  • 63
  • 91