Assembly Resources

Assembly resources in a WPF application work in essentially the same way as assembly resources in other .NET applications. The key difference is the addressing system that you use to refer to them.

NOTE

Assembly resources are also known as binary resources because they're embedded in compiled assembly (the EXE or DLL file for your project) as an opaque blob of binary data.

You've already seen binary resources at work in Chapter 2. That's because every time you compile your application, each XAML file in your project is converted to a BAML file that's more efficient to parse. These BAML files are embedded in your assembly as individual resources. It's just as easy to add your own resources.

Adding Resources

You can add your ...

Get Pro WPF in C# 2008: Windows Presentation Foundation with .NET 3.5, Second Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.