473,473 Members | 1,954 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Problem parsing XML with SAX in WSAD - Please help!

I have written a SAX parser to read a simple XML file using this code
:

SAXParserFactory factory = SAXParserFactory.newInstance();

javax.xml.parsers.SAXParser saxParser = factory.newSAXParser();

saxParser.parse(new File(filePath),new PurgeHandler());

For some reason, when the code enters the characters(char[] buf, int
offset, int len) method of my handler, the 'len' is not correct
sometimes, so the String returned by the code
new String(buf,offset,len)
is just part of the content of my element.

Any help please?

Thanks!!
Jul 20 '05 #1
0 1449

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: burn_hall | last post by:
Hi, I have a problem and can't figure it out and need your help, please look at the following code and the output also a xml file snippet is down there too. Looking at the output I don't know why...
0
by: abwabe | last post by:
im using WSAD 5.0 when i try to execute this : public static void main(String args) { myHash = new Hashtable(); try { String strHtmlFile = "C:\\test.html";
1
by: jrefactors | last post by:
I posted this question before but no replied. I really need some suggestions. The JSP application is deployed in IBM Websphere, and it has file upload operation. The problem is if the user...
0
by: Juan Carlos Huitzache | last post by:
Hi, I am trying to build a very simple Java stored procedure on DB2 V8.2 for AIX. I use the WSAD 5.1 or the DB2 Development Center with the same result: C:\Program Files\SQLLIB\java\jdk\bin\jar...
6
by: Ulrich Vollenbruch | last post by:
Hi all! since I'am used to work with matlab for a long time and now have to work with c/c++, I have again some problems with the usage of strings, pointers and arrays. So please excuse my basic...
10
by: Bryce Calhoun | last post by:
Hello, First of all, this is a .NET 1.1 component I'm creating. SUMMARY ----------------------- This component that I'm creating is, for all intents and purposes, a document parser (I'm...
1
by: tom.eeraerts | last post by:
Hello, I have a problem migrating an application from v5r2 to v5r3. The problem is with the prepared statements. To see what the problem is, i extracted a small piece of code and debugged the...
6
by: java4u1129 | last post by:
Hi All, I am a new bie to WSAD, can any one suggest me any source to develop simple java applications and web applications. Thanks All.
0
by: pancy | last post by:
can somebody detail the steps for db2 and wsad connectivity?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.