/ProfessionalCSharp7

Code samples for the book Professional C# 7 and .NET Core 2.0 (with updates for 2.1), Wrox Press

Primary LanguageC#MIT LicenseMIT

Professional C# 7 and .NET Core 2.0

Check Professional C# and .NET - 2021 Edition for the code samples of the next edition of the book.

Code samples for the Wrox Press book Professional C# 7 and .NET Core 2.0

To compile and run the samples, you need Visual Studio 2017, Visual Studio for Mac, or Visual Studio Code.

You can download these tools here: Visual Studio.

The console app samples can be used on Windows, Linux, or Mac. Here is the installation procedure for .NET Core: .NET on Linux

If you're using Visual Studio, Update 5 or a later version of Visual Studio 2017 is needed. With the Visual Studio Installer you need to select this workload to compile most of the code samples: .NET Core cross-platform development.

ASP.NET Core samples need this workload: ASP.NET and web development.

Windows app samples require Windows 10, Windows 10 Fall Creators Update (build 16299) or a later version. With the Windows app samples, Visual Studio 2017 Update 5 is required with this workload: Universal Windows Platform Development.

Compiling the Xamarin samples, you have different options using a Mac or a Windows system:

  • On the Mac, you can install Visual Studio for Mac to compile the Android and iOS samples.

  • On Windows 10, you can use Visual Studio 2017. To compile the iOS samples, you also need a Mac. Using only Windows 10, you can compile and run the Windows and Android code samples.

  • Visual Studio 2017 with the .NET Core workload

Here's the list of chapters and the folders for the code samples:

  • Chapter 1 - .NET Applications and Tools (HelloWorld)
  • Chapter 2 - Core C# (CoreCsharp)
  • Chapter 3 - Objects and Types (ObjectsAndTypes)
  • Chapter 4 - Object-Oriented Programming with C# (ObjectOrientation)
  • Chapter 5 - Generics (Generics)
  • Chapter 6 - Operators and Casts (OperatorsAndCasts)
  • Chapter 7 - Arrays (Arrays)
  • Chapter 8 - Delegates, Lambdas, and Events (Delegates)
  • Chapter 9 - Strings and Regluar Expressions (StringsAndRegularExpressions)
  • Chapter 10 - Collections (Collections)
  • Chapter 11 - Special Collections (SpecialCollections)
  • Chapter 12 - Language Integrated Query (LINQ)
  • Chapter 13 - Functional Programming with C# (FunctionalProgramming)
  • Chapter 14 - Errors and Exceptions (ErrorsAndExceptions)
  • Chapter 15 - Asynchronous Programming (Async)
  • Chapter 16 - Reflection, Metadata, and Dynamic Programming (ReflectionAndDynamic)
  • Chapter 17 - Managed and Umanaged Memory (Memory)
  • Chapter 18 - Visual Studio 2017 (VisualStudio)
  • Chapter 19 - Libraries, Assemblies, Packages, and NuGet (Libraries)
  • Chapter 20 - Dependency Injection (DependencyInjection)
  • Chapter 21 - Tasks and Parallel Programming (Tasks)
  • Chapter 22 - Files and Streams (FilesAndStreams)
  • Chapter 23 - Networking (Networking)
  • Chapter 24 - Security (Security)
  • Chapter 25 - ADO.NET and Transactions (ADONet)
  • Chapter 26 - Entity Framework Core (EFCore)
  • Chapter 27 - Localization (Localization)
  • Chapter 28 - Testing (Tests)
  • Chapter 29 - Tracing, Logging, and Analytics (Diagnostics)
  • Chapter 30 - ASP.NET Core (ASPNETCore)
  • Chapter 31 - ASP.NET Core MVC (MVC)
  • Chapter 32 - Web API (API)
  • Chapter 33 - Windows Apps (Windows)
  • Chapter 34 - Patterns with XAML Apps (Patterns and PatternsXamarinShared)
  • Chapter 35 - Styling Windows Apps (Styles)
  • Chapter 36 - Advanced Windows (AdvancedWindows)
  • Chapter 37 - Xamarin.Forms (Xamarin and PatternsXamarinShared)

Bonus Chapters

  • Bonus Chapter 1 - Composition (Composition)
  • Bonus Chapter 2 - XML and JSON (XMLandJSON)
  • Bonus Chapter 3 - SignalR and WebHooks (SignalRAndWebHooks)
  • Bonus Chapter 4 - Bots and Cognitive Services (BotAndCognitive)
  • Bonus Chapter 5 - More Windows Apps Features (MoreWindows)
  • Bonus Chapter 6 - What's new with C# 8 (CSharp8)

In case you've some issues to compile and run the samples, create an issue in the Professional C# 7 GitHub repository.

Have fun coding and enjoy the book!

Christian