Chapter 16. User Controls Combining WPF and Windows Forms

WHAT YOU WILL LEARN IN THIS CHAPTER

  • The Windows Forms Integration Library

  • Using WPF controls in Windows Forms

  • Using Windows Forms controls in WPF

  • Integration library limitations

Chapter 15 looked at advanced features of Windows Forms. One of these features goes well beyond Windows Forms: user controls. User controls are used in Windows Forms, ASP.NET, WPF, and Silverlight. The concepts around user controls reflect a best practice for encapsulating application logic within a reusable component. Within an application, smaller components that encapsulate functionality and communicate via a method such as events provide a robust architecture. This chapter acts as a bridge to the next chapter which deals with WPF and also references using a user control.

The same concept is used to provide a migration path from Windows Forms to Windows Presentation Foundation (WPF). WPF was first introduced in .NET 3.0 as Microsoft's next-generation solution to graphical user-interface development. In terms of user interfaces, the transition to this new model will be similar in significance and paradigm shift to the shift from COM-based Visual Basic to Visual Basic .NET. The core paradigms and syntax familiar to developers of Windows applications are changing, and most of the changes are not backwardly compatible.

As a result, developers will need to transition existing application source code to a new technology paradigm. Perhaps not this year or next, ...

Get Professional Visual Basic® 2010 and .NET 4 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.