XmlReader and XmlWriter – the easy way to write XML data in C#

Опубликовано: 06 Март 2025
на канале: Code With Huw
6,460
80

XML is a good format when you want to save multiple types of data in a single human-readable file on disk. If you want to save and load XML using C# and .NET, the two classes you need to use are called XmlReader and XmlWriter.

In this lesson, I show a simple way to read and write XML data files. This is the latest in my series on programming quite complicated applications in the C# language. Here I show how I use XML data files to store the document paths and URLs needed by my application and web-page Launchpad project.

For more C# Programming Projects, see this Playlist:    • C# Programming Projects  

To understand file launching, I’d also recommend that you watch my lessons on programming a Disk Browser – which you can find here:    • How to Program A Disk Browser in C#  

Huw Collingbourne is author of numerous books on programming C, C#, Java, Ruby, Delphi and Object Pascal, pointers, recursion and programming adventure games. Find them all on Amazon.

To learn C# quickly, Huw’s book, available in paperback or for Kindle, is the perfect complement to these YouTube lessons.
The Little Book Of C# Programming (Amazon US): https://amzn.to/2JWDI0o
The Little Book Of C# Programming (Amazon UK): https://amzn.to/2YaCPtS

Keep in Touch
==============================
Subscribe to the Code With Huw YouTube channel: https://www.youtube.com/CodeWithHuw?s...

Code With Huw on Facebook:
  / codewithhuw