Consider using XmlPullParser instead of SAX. It's more convenient for the most cases.
On Aug 23, 1:20 pm, Atokarev <[email protected]> wrote: > Hi there. I could not get any inner elements during the xml parsing. > looks like parser see only outer tag A. > Could you show me error? > > XML: > <A> > <B b="ab"></B> > <C c="ac"></C> > <D d="ad"></D> > <E e="ae"></E> > </A> > When i call parse function - only A-tag was processed. > Code: > > App_class > > ... > xr.parse(new InputSource(url.openStream())); > ... > > ExampleHandler: > ... > if (localName.equals("A")) > { > // TODO > } > if (localName.equals("B")) > { > String a= atts.getValue("b"); > myParsedExampleDataSet.setExtractedB(b); > values.put("b", b); > } > else if (localName.equals("C")) > { > int c = Integer.parseInt(atts.getValue("c")); > myParsedExampleDataSet.setExtractedC(c); > values.put("c", c); > } > else if (localName.equals("D")) > { > double d= Double.parseDouble(atts.getValue("d")); > myParsedExampleDataSet.setExtractedD(d); > values.put("d", d); > } > ... -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

