Book Image

.NET Standard 2.0 Cookbook

By : Fiqri Ismail
Book Image

.NET Standard 2.0 Cookbook

By: Fiqri Ismail

Overview of this book

The .NET Standard is a standard that represents a set of APIs that all .NET platforms have to implement, making it easy for developers to access and use one common library for their development needs. This book begins with a quick refresher, helping you understand the mechanics of the new standard and offering insight into how it works. You’ll explore the core library concepts, such as working with collections, configurations, I/O, security, and multithreading. You’ll explore the iOS and Android libraries of Xamarin and we’ll guide you through creating a .NET Standard 2.0 library, which you’ll use with both Android and iOS applications. In the final chapters, you’ll learn the various debugging and diagnostics tools to deliver quality libraries and create a NuGet package of the .NET Standard 2.0 library. By the end of this book, you’ll be able to expand your current workflow to various .NET flavors and have the essential skills to create a .NET Standard 2.0 library from scratch to package and deliver it to the world.
Table of Contents (18 chapters)
Title Page
Copyright and Credits
Packt Upsell
Contributors
Preface
Index

Putting things together and testing the application


In this recipe, we will be adding some controls to the iOS application and using the .NET Standard 2.0 library created in the previous recipe.

Getting ready

Make sure you have completed the previous two recipes. They are required in order to continue. If you have already completed them, let's perform a quick build and start.

How to do it...

  1. Open Finder.
  2. Click Applications in the left-hand pane.
  3. Double-click on the Visual Studio icon.
  4. Click on Open, locate the Chapter8.Xamarin solution, and open it.
  1. The Solution Explorer should look like this:
  1. Now, expand the Chapter8.Xamarin.iOSApp project node.
  2. Double-click on the Main.storyboard file.
  3. This will open the storyboard tab for your application.
  1. You should see the default layout of the iOS application as follows:

Default layout of the iOS application

  1. Now, select the Toolbox window.
  2. Click inside the search textbox and type Button.
  3. Now, drag a Button control to the main white area of the canvas, in the middle...