Code for a Simple Way to Write XML in .NET (XmlTextWriter)



Code for a Simple Way to Write XML in .NET (XmlTextWriter)..

Answer / mohanraja

This coding is to decrement the count value...

Dim writer As New XmlTextWriter("C:\windows\Test.xml", New
System.Text.UTF8Encoding)
writer.WriteStartDocument()
writer.WriteStartElement("Value", "")
writer.WriteStartElement("Countvalue")
writer.WriteStartElement("cntval", "")
writer.WriteString(value - 1)
writer.WriteEndElement()
writer.WriteEndElement()
writer.WriteEndElement()
writer.WriteEndDocument()
writer.Close()

Is This Answer Correct ?    2 Yes 1 No

Post New Answer

More ASP.NET Code Interview Questions

how to create a search bar which access data from various websites and retrieves the data

0 Answers  


ArrayList declaration in .net

0 Answers  


How to get the row index on checking a Checkbox in a ListView

1 Answers  


how to design a ListView control?

1 Answers  


How to integrate the regional language in asp.net and c# like Telugu, Hindi etc,. send a sample program

3 Answers   Concept, NIIT, Wipro,






Give coding for Exception Handling Techniques in ASP.NET?

3 Answers   Microsoft,


How we use ajax in asp.net through javaScript. Please givee me an example.

0 Answers  


How to Bind Nested XML to a Repeater Control with Container.DataItem?

0 Answers  


Code for Document Validation in XML.NET?

0 Answers   TCS,


Code for Getting Information About A File?

1 Answers  


Code for Sending E-Mail with System.Web.Mail?

2 Answers  


Code for Creating a Form Using PlaceHolder Controls?

0 Answers   Arena, JSA,


Categories
  • ASP.NET Code Interview Questions ASP.NET Code (46)
  • VB.NET Code Interview Questions VB.NET Code (9)
  • C Sharp Code Interview Questions C Sharp Code (51)
  • ADO.NET Code Interview Questions ADO.NET Code (8)