Windows Presentation Foundation Using C# – 4 Days
This four-day Windows Presentation Foundation Using C# course is designed to provide a sound introduction to the .NET Framework for programmers who already know the C# language and the fundamentals of Windows Forms. It is current to Visual Studio 2017, which now includes support for cross-platform development using .NET Core. The course focuses on core portions of the .NET Framework that are common across many application areas. Separate courses are available in specific areas, such as ADO.NET, XML Programming, Windows Presentation Framework, Windows Communications Framework and ASP.NET.
Microsoft .NET is an advance in programming technology that greatly simplifies application development, both for traditional, proprietary applications and for the emerging paradigm of Web-based services. .NET is a complete restructuring of Microsoft’s whole system infrastructure and represents a major learning challenge for programmers developing applications on Microsoft platforms. Part of .NET is a major new object-oriented programming language, C#. But learning the new programming language is only part of the challenge. The much greater challenge is learning the .NET Framework and all its capabilities.
The course starts with an introduction to the architecture and key concepts of .NET. It then discusses class libraries, assemblies, versioning, configuration, and deployment, which constitute a major advance in the simplicity and robustness of deploying Windows applications, ending the notorious “DLL hell.” The next four chapters discuss important topics in the .NET programming model, including metadata, reflection, I/O, and serialization. Chapter 6 continues the discussion of the .NET programming model, covering memory management, asynchronous programming and application domains. Next comes a chapter on threading, which includes an introduction to the Task Parallel Library (TPL).
.NET Security, which was simplified in .NET 4.0, is introduced, including both code access security and role-based security. The next chapter covers interoperability of .NET with COM and with Win32 applications. The course includes an introduction to database programming using ADO.NET and LINQ. Finally, the .NET Framework diagnostic facilities are discussed in depth. An appendix covers .NET Remoting.
The course is practical, with many examples and a case study. The goal is to equip you to begin building significant applications using the .NET Framework. The student will receive a comprehensive set of materials, including course notes and all the programming examples.
What You Will Learn
- Gain an understanding of the philosophy and architecture of WPF
- Create Windows applications using the classes provided by WPF
- Understand the principles of XAML and create applications using a combination of code and XAML
- Use the layout features of WPF to create flexible and attractive user interfaces
- Implement event and command-driven applications with windows, menus, dialogs, toolbars, and other common user interface features
- Use more advanced features of WPF such as dependency properties, routed events, logical resources, styles, templates, and data binding
- Access databases using Visual Studio 2017 and the Entity Framework 6
- Learn how to interoperate between WPF and Windows Forms
A working knowledge of C# and the .NET Framework.
Introduction to WPF
What Is WPF?
.NET Framework 4.0 and Later
.NET Core and WPF
Application and Window
A Simple WPF Application
Using Visual Studio 2017
Role of XAML
Elements and Attributes
XAML and Procedural Code
3. WPF Controls
Win32 Common Dialogs
Custom Modal Dialogs
Custom Modeless Dialogs
6. Menus and Commands
Icons on Menu Items
Disabling Menu Items
Checking Menu Items
7. Toolbars and Status Bars
Toolbars and Commands
8. Dependency Properties and Routed Events
Property Value Inheritance
Support for Multiple Providers
Resources in WPF
Static versus Dynamic Resources
10. Data Binding
Sharing Sources with DataContext
Visual Data Binding Using Visual Studio 2017
Database Access Using Entity Framework
11. Styles, Templates, Skins and Themes
Templated Parent’s Properties
12. Windows Forms and WPF Interoperation
Mixing Forms and WPF Windows
Appendix A. Learning Resources
Required software is Visual Studio 2017, which includes LocalDB, a lightweight version of SQL Server 2016 Express. The free Visual Studio Community 2017 can be used. The operating system should be Windows 7SP1 or more recent. See the appropriate course Setup Guide for details.
A good minimal hardware profile for this course would have a 2 GHz or better CPU, 2 GB of RAM (4 GB recommended), and at least 10 GB of free disk space for tools installation and courseware.