[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pnet-developers] [bug #4194] XmlReader.ReadAttributeValue doesn't work
From: |
nobody |
Subject: |
[Pnet-developers] [bug #4194] XmlReader.ReadAttributeValue doesn't work properly |
Date: |
Sat, 05 Jul 2003 06:52:38 -0400 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3a) Gecko/20021207 Phoenix/0.5 |
=================== BUG #4194: LATEST MODIFICATIONS ==================
http://savannah.gnu.org/bugs/?func=detailbug&bug_id=4194&group_id=353
Changes by: Adam Ballai <address@hidden>
Date: Sat 07/05/2003 at 10:52 (GMT)
What | Removed | Added
---------------------------------------------------------------------------
Status | Open | Closed
------------------ Additional Follow-up Comments ----------------------------
fixed.
=================== BUG #4194: FULL BUG SNAPSHOT ===================
Submitted by: tum Project: DotGNU Portable.NET
Submitted on: Sat 07/05/2003 at 00:27
Category: None Severity: 5 - Major
Bug Group: None Resolution: None
Assigned to: None Status: Closed
Summary: XmlReader.ReadAttributeValue doesn't work properly
Original Submission: A call to ReadAttributeValue should move the reader into
a state where you can potentially read nodes "inside" an attribute. If the
attribute only contains text (no entity references etc) then ReadAttributeValue
should "move" the reader into a a text node.
Here's some code to demonstrate what I mean:
using System;
using System.IO;
using System.Xml;
using System.Text;
public class TestXml
{
public static void Main()
{
string xml;
xml = @"<?xml version='1.0'?>
<element a1='pok' a2='wer'/>
";
XmlReader reader = new XmlTextReader(new StringReader(xml));
for (;;)
{
reader.MoveToContent();
if (reader.NodeType == XmlNodeType.Element)
{
reader.MoveToFirstAttribute();
reader.ReadAttributeValue();
Console.WriteLine(reader.NodeType);
return;
}
}
}
}
It should print out "Text" but it prints out "Attribute".
Follow-up Comments
*******************
-------------------------------------------------------
Date: Sat 07/05/2003 at 10:52 By: minddog
fixed.
CC list is empty
No files currently attached
For detailed info, follow this link:
http://savannah.gnu.org/bugs/?func=detailbug&bug_id=4194&group_id=353
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/