hi,
this is dhana. this is my first post, i am little nervous. i am developing a j2me application, i used xml file as database. so, i created a xml file and i saved it in c:\ , when i am trying to open that file in j2me, it shows error. the code is as below:
c =(StreamConnection)Connector.open("c:\\addressbook.xml");
s = c.openInputStream();
Reader is= new InputStreamReader(s);
KXmlParser parser = new KXmlParser();
Document document = new Document();
parser.setInput(is);
i am getting arror as below:
C:\Users\DHANA\Documents\NetBeansProjects\AddressBook\src\AddressDB.java:128: unreported exception org.xmlpull.v1.XmlPullParserException; must be caught or declared to be thrown
parser.setInput(is);
C:\Users\DHANA\Documents\NetBeansProjects\AddressBook\src\AddressDB.java:129: unreported exception org.xmlpull.v1.XmlPullParserException; must be caught or declared to be thrown
document.parse(parser);
2 errors
C:\Users\DHANA\Documents\NetBeansProjects\AddressBook\nbproject\build-impl.xml:368: Compile failed; see the compiler error output for details.
BUILD FAILED (total time: 3 seconds)
so, can anyone solve my problem. thanks in advance.