How to access attributes using "xmlreader", DOT NET Programming

How do we access attributes using "XmlReader"?

The below snippets represents the way to access attributes. At First in order to check whether there any attributes present in the current node you can use "HasAttributes" function and use the "MoveToNextAttribute" method to move forward in attribute. Just in case you want to move to the next element use "MoveToElement()".

if (reader.HasAttributes)




// your logic goes here

string pdata = reader.Value




Posted Date: 9/25/2012 2:57:57 AM | Location : United States

Related Discussions:- How to access attributes using "xmlreader", Assignment Help, Ask Question on How to access attributes using "xmlreader", Get Answer, Expert's Help, How to access attributes using "xmlreader" Discussions

Write discussion on How to access attributes using "xmlreader"
Your posts are moderated
Related Questions
How object pooling in .NET is done COM+ reduces overhead by creating object from scratch. Thus  in COM+ when object is activated its activated from pool and when its deactivate

Problem: (a) (i) Using a diagram, illustrate the basic process in an ASP.NET Architecture involving at least five objects. (ii) List two methods and two collections

What is the significance of Finalize method in .NET? The .NET Garbage collector does atmost all clean up activity for your objects. But unmanaged resources (like - Windows API

Explain the DataAdapter.Update() and DataSetAcceptChanges() methods. The DataAdapter.Update() method calls any of the DML statements, like UPDATE, INSERT, or DELETE statements,

Describe the role that XSL can play while dynamically generating HTML pages from a relational database. The SQLXML 3.0 and advanced versions give the facility of mapping the SQ

Update current website backend (asp.NET) and build Rest API to expose data I will shortly shape an HTML5 cross-platform mobile app. I at present have a website with a backend th

Need to get a windows desktop application developed Project Description: I am looking to obtain a desktop application developed. The desktop application will have the subsequ

Training and placement cell Project Description: It is about placement and training cell of any college. I have made this for one college. If needed, i can modify it. Student

What is an interface and what is an abstract class? Please, expand by examples of using both. Explain why.   In a interface class, all methods are abstract without execut

What are value types and reference types?  Value type - bool, byte, chat, decimal, double, enum , float, int, long, sbyte, short, strut, uint, ulong, ushort. Value types are