logo       

Error verifying class: msg#00007

java.enhydra.kxml

Subject: Error verifying class

I am using Borland JBuilder Mobile Edition 9 to develop a J2ME MIDlet and I
have installed the kXML zip file, I think succesfully. I am able to import the
classes and access the methods but if I try to instantiate a new KXmlParser I
receive the following error:

"Error verifying method org/kxml2/io/KXmlParser <init>()V
Approximate bytecode offset 65: Inconsistent or missing stackmap at target
ALERT: Error verifying class org/kxml2/io/KXmlParser"

Below is the source:

String sXml =
"<employee><firstname>John</firstname><lastname>Doe</lastname><sex
type='male'/><email valid='true'
primary='true'>jdoe@xxxxxxx</email></employee>";
byte[] baXml = sXml.getBytes();
// create an input stream from the byte array
ByteArrayInputStream stream = new ByteArrayInputStream(baXml);
int nCnt = -1;
nCnt = stream.read(baXml);
KXmlParser pxml = new KXmlParser();
----------------------------------------------------------------------- This is
line of code that fails ----------------------------------------------------
pxml.setInput(stream, "Default");

Any help would be greatly appreciated?

Thank You


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise