Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
.NET Standard 2.0 Cookbook

You're reading from   .NET Standard 2.0 Cookbook Develop high quality, fast and portable applications by leveraging the power of .NET Standard Library

Arrow left icon
Product type Paperback
Published in May 2018
Publisher
ISBN-13 9781788834667
Length 394 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
 Ismail Ismail
Author Profile Icon Ismail
Ismail
Arrow right icon
View More author details
Toc

Table of Contents (18) Chapters Close

Title Page
Copyright and Credits
Packt Upsell
Contributors
Preface
1. Back to Basics FREE CHAPTER 2. Primitives, Collections, LINQ, and More 3. Working with Files 4. Functional Programming 5. XML and Data 6. Exploring Threading 7. Networking 8. To iOS with Xamarin 9. To Android with Xamarin 10. Let’s Fine-Tune Our Library 11. Packaging and Delivery 12. Deploying Index

Creating a library that reads and writes to an XML file


In this recipe, we will be using a .NET Standard 2.0 library to create and write to an XML file. We will also be using the same library to write data to an XML file.

Getting ready

Let's fire up Visual Studio 2017 and get things done. Make sure you have the latest version of Visual Studio 2017 installed.

How to do it...

  1. Open Visual Studio 2017.
  2. Click File | New | Project to create a project. 
  3. In the New Project dialog box, expand the Other Project Types node in the left-hand pane and select Visual Studio Solutions. In the right-hand pane, select Blank Solution.
  4. In the Name: textbox, type Chapter5.XmlDoc and, in the Location: textbox, select path from the drop-down box or click on the Browse... button to locate a path:
  1. Click OK.
  1. Now, the Solution Explorer(Ctrl+Alt +L) should look like this:
  1. Now, right-click on the Chapter5.XmlDoc label in the Solution Explorer and select Add | New Project.
  2. In the New Project dialog box, expand the Visual C# node...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime
Visually different images