Pro WPF in C# 2008: Windows Presentation Foundation with .NET 3.5, Second Edition



Price: $34.64


Pro WPF in C# 2008: Windows Presentation Foundation with .NET 3.5, Second Edition (Apress) - February 2008Publisher: Apress - February 25, 2008

ISBN-10: 1590599551, ISBN-13: 9781590599556

Author: Matthew MacDonald


1040 pages


Pro WPF in C# 2008: Windows Presentation Foundation with .NET 3.5, Second Edition





Customer Reviews

Nothing pro about this one

I'm very disappointed with this book. I have now had WPF Unleashed, Pro WPF in C# 2008, and Programming WPF for several month, and time and time again I try to look something up in the Pro book only to get frustrated over the lack of `anything' more than just the regular information you can find in MSDN help. Just the other day I needed some detailed info on GlyphRunDrawing, looked in the index, cool - it is there, go to the page, the word GlyphRunDrawing is there in a table over drawing classes - nothing else. And it seems to be the same every single time I try to look for something, no real useful information.
Do now spend your money on this book. Are you starting in WPF go with the Unleashed, are you looking for a deeper book go with Programming WPF.



jkr
22 July, 2010


Prompt and good value

I tried to buy this product locally, not only was the price high, but delivery would have taken up to four weeks. For a major capital city, this was unacceptable. I have no guilt about buying this book from Amazon - half the price and arrived within a week. Brilliant.

Gregg Helleren
14 July, 2010


A great book!

This rates high in my opinion. Lots of really great examples with plenty of "internals" knowledge exposed. The author did a great job organizing and put in ample detail. I recommend this book to anyone serious about WPF.

John W. Peters
27 May, 2010


Thorough, a good resource, but slow and boring...

If you know nothing about WPF, this book will teach you and I'm sure, do a great job. At 1000+ pages it's very thorough, but if your already a seasoned WinForms programmer, you may find it a little too thorough. At times this read more like a "for dummies" book. Basic topics are explained such as what a list box is and the consequence of adding events. This book probably could have been cut down to half the size if the audience were credited with a little more intelligence, after all this is a "Pro" WPF book? Such an example of "bloat" is:

"Because ApplicationCommands.Open is a static property, there is only one instance of the Open command for your entire application."

Come on! Do we really need to be reminded how static objects work? Having to read this extra and unnecessary blurb is tiring.

If you have minimal programming experience you may find all this useful, but for someone who is more skilled and just wants to know how WPF differs from the traditional WinForms model you're probably going to find this painful. A "Quick Start" guide this is not. I found myself getting very bored reading about what a combobox does but not wanting to skip anything in case a missed an important WPF specific feature. As a busy developer I just don't have time to sort out the important bits.

Pros: Thorough, comprehensive.
Cons: Boring, slow going (isn't it a "Pro" book), no central theme to the book (example program, etc)

Summary: Great for the real beginners, anyone with more than a years programming experience may want to look elsewhere.

M. Bird
21 May, 2010


Great gem for detailed WPF knowledge

I use the book as the reference for all of my WPF questions. Every time I read or reread a chapter, I develop greater understanding of WPF and how to best utilize it. I plan to get the new edition of this book.

FARIAZ KARIM
11 May, 2010


Good book

Just finished this monster of a book and have to say it is one of the books I not only enjoyed but will undoubtably be referring to constantly at work.

The Writer explains everything in WPF in detail, good step through on code examples with C# and XAML. His coding is clean, minimal, and excellently done.

I would have given this book 5 stars easily except a few peeves. It appeared to me the chapters were a bit out of sync and switched around from topics I thought should have been put closer together. Not a big deal, just made the reading flow a bit disjointed. My only other minor issue was the Writer was at times a bit too verbose, "too much detail" so to speak.

That said, I still highly recommend this book!

Kyle Munkittrick
25 April, 2010


Mixed Emotions

I have mixed emotions about this book. The organization is not good. If you are looking for information about a particular technology (ControlTemplate vs UserControl, etc), it is not well organized. I have hit quite a few gotchas after reading this book twice before getting real deep into WPF. As a reference it leaves a lot to be desired. I still do not understand much about the details of his class diagrams. I was much happier with the "Exam 70-502 Microsoft .NET Framework 3.5: Windows Presentation Foundation" because if provided information on what the interface of the DependencyProperty class. I am very bothered by including material that not directly related to understanding WPF. The Author spent a lot of time on linking to a database, and that really should be beyond the subject of the book. I also not sure about the time he spent on getting the Aero look. Still the book was helpful, but the web was more so.

Clifford Nelson
16 April, 2010


A thorough examination of the WPF 3.5 technology

This book is a thorough examination of the WPF 3.5 technology - its architecture, what you can do with it, and how to do it. It is directed at professional C# developers.

The book is written in a systematic, comprehensible way. A chapter starts with a basic introduction and includes graphics of the respective WPF sub-class hierarchy. The chapter's subject is then steadily explored in more and more detail. For instance, at the beginning, there are five pages just on resolution independence. XAML is explained in-depth, starting with the four ways of loading and compiling: Code-only, code and uncompiled XAML, code and compiled XAML, and XAML only; this is followed by the specifics of the XAML grammar (markup extensions, attached properties, etc.). There are seven pages on non-rectangular windows and sixteen pages on playing sound on different OS versions. As the book goes on, the author really shines in describing complex subjects, such as 3-D drawing, in a logically understandable way. Towards the end, there is a tabular overview of features missing in WPF compared to Windows Forms, with recommendations on when to choose one over the other, or both of them together, and how to mix them best.

The volume also contains lots of small, but precious pieces of surplus information, such as: Properties of WPF controls can be set in any order, without causing any change in behavior; or: By using an overloaded version of DependencyObject.SetValue in code, you can attach a value for any dependency property, even if it is not defined as an attached property (which is not possible in XAML). In addition, the author mentions various quirks of WPF, and how to get around them, if possible. Example: When you restart an animation that is almost complete, and the animation had the current position as the starting point, the animation will appear to slow down. Another example: Windows Vista always requires permission elevation for a setup, even though, in the case of Click Once, this makes no sense. As a consequence, a Click Once WPF application, on Vista, cannot be installed under a regular user account; the user is forced to install it under an admin account - which defeats the purpose of using Click Once in the first place...

Developers are all-too-familiar with the Pareto principle: 80% of the tasks of a project can be solved easily" in 20% of the time, but solving the other 20% takes at least 80% of the time. If you want to use WPF in a productive way, I strongly recommend taking the time to study this book. Admittedly, at 1040 pages, this is quite some endeavor. However, you will be rewarded many times over, as you will be saved a lot of frustration and unexpected delays, when you already know from the beginning how to solve much of the other 20%.

Marc Sigrist
28 February, 2010


Highly Informative

Just bought a copy at Amazon-Japan, and have completed most of it. I was initially determined to use just the MSDN documentations/online articles to study both the WPF and Silverlight, but was assigned a new project, which I decided to do in WPF. I have spent the week/weekend on this book, and highly impressed, and very confident on delivering a good product by God's grace.

Technically, it is a well-written book, and I will highly recommend it to anyone. It is an intermediate (more) to advance level (since I do not know exactly how the Pro tag applies). His explanations of the concepts are really joy to read.
That said, I think it is too verbose in many parts, which really do not deserve all that much of information. Like using 11 lines just to *introduce* Background and Foreground Brushes of Controls!

There are two main problems with the book (why I will not give it 5 points)
1. Depth, you will complete the 1040 WPF Pro book without knowing who the XAML namespaces you type are actually mapped to the code namespaces in your library. I normally read two or more books at the same time on a subject and this time it was the Windows Presentation Foundation Unleashed, which completed that missing part for me.
2. Organization of the book, I know it is a difficult part, but this book could be better and much more fun if the chapters/contents were better organized. Let me give some examples to illustrate this...

A. WPF concepts like Dependency Properties and Routed Events (chapter 6) are fundamental to understanding the WPF and new to C# programmer, and you do not need to understand Contents (chapter 5) to be able to understand these concepts so why wait till chapter 6?

B. Shapes, Transforms and Brushes (chapter 13), which could easily come after the Layout (chapter 4) and its treatment of Canvas. Then a lot of justice could be done to the Classic Controls (chapter 7), but rather you are often told that you learn about brushes later.

The last chapter, ClickOnce Deployment is just a sort of introduction on that topic. The simply WPF tip at the beginning could be treated as Application Deployment in The Application (chapter 3).

The author is very knowledgeable, with much experience on the subject, and I guess is burdened by the lack of "Beginning WPF" book from the same publisher to be too narrative. If he could polish this work in the coming edition, it could be the single most important book on WPF.

Paul Selormey
07 February, 2010


Thorough introduction to WPF

Pro WPF provides a comprehensive overview of WPF technologies. It covers most topics that a programmer may need to know to use WPF for creating applications.
The chapters on available controls, on styles, control templates, pages , layout, styles and triggers and on data binding were useful to me professionally.

The chapter on dependency properties and routed events is a must read to understand how WPF is meant to be used.

The data binding chapters are good but could do with more detail. The chapter on multithreading could use more detail too.

Overall this book seems better than another WPF book I have read(unleashed).

Tanveer Ansari
06 February, 2010


Not a good book to start with if you are novice

+ve points:

1. Extensive

2. Enough examples

3. Okay kind of narration

-ve points:

1. Unclear development: For example author talks about Attached properties almost for a page and Dependency properties for several pages. But had he explained in a more clear way that Attached properties are nothing but XAML syntactical sugar and Dependency properties are not actual properties rather they are objects stored in a Hashmap or something like that, it would have much more better. So basically clarity is missing. Author should have stressed on the need

2. Too big to read: Well I need to agree there is lot to cover. But it would have been better this book is around 500-600 pages

3. I personally did not like the chapter organization. I don't say organization is completely bad but it would have been better if menus and menu bars are covered in the controls section

This book would have much more better had this book been developed more clearly on the basis of why WPF had to be different from the earlier MS GUI frame work including Forms programming

So the gist is, it is okay if you buy this book but first you need to make your feet wet some where. I personally liked the following tutorial:

[...]


Fact Pandit
14 December, 2009


Best WPF book out there so far...

I purchased many of the WPF books out there for myself and my team. This book has become my new favorite (with Chris Sells WPF book coming in second - sorry Chris!). The book goes into more details about why things work the way they do instead of just saying this is how it should be done. Books that provide deep understanding of a topic are hard to find in today's mantra of pushing low budget tech books out the door for copy and paste code examples. The author finds just the right balance of code, pictures and words. With this book you get 800 pages of information and not 800 pages of code examples printed page after page after page.

Todd
08 November, 2009


Good book

This book presents the subject well and I recommend it to the other programmers who want to learn about this subject.

Ricardo Sanchez
02 November, 2009


Very complete WPF reference

While waiting for a 2010 edition, probably the best and most complete WPF book around.

Dalmonte Roberto
12 September, 2009


Nothing more than a list of manual

Nothing but a huge list of manuals.
I don't think we have time to read the huge manuals to get started with WPF in these fast changing times.

And it was boring! Just think about reading 1000 pages of manual!

H. Kim
04 September, 2009


good ref for wpf but doesn't help your wpf programmming skills


I like the fact that this book is bulky and a good reference to wpf
Don't like the fact that it doesn't show you any programming struture for using the code
Reminds me of the cut and paste in vb5 from the msdn cds
Maybe the author should write another book on wpf programming structures/framework

.Net learner
26 August, 2009


Shallow

If you think you will get anything beyond the very basics of WPF with this book, you're wrong.
I found the text to be very shallow. There is nothing "Pro" about this book. The examples are super trivial.
It should have been labelled "basic" or "get your feet wet" with WPF.


Jeff Saremi
17 August, 2009


An Invaluable Resource for the WPF Developer

This is one of a handful of books that stays on my desk at all times, and it is usually open. I find myself constantly referring to it as a resource for important WPF concepts and samples. I have not found another book yet that covers the topics I need as thoroughly as this one does.

I would not recommend this as the first book one should read on WPF. The scope of the book is very wide and the coverage is deep and may quickly overwhelm a reader who has not already been exposed to the basics. That being said, I wholeheartedly recommend this book for anyone with at least introductory exposure who has more than a passing interest in WPF and XAML.

Joel Cochran
03 August, 2009


The one book to have

Having been a programmer for more than 15 years, but moved into management for the last five, I wanted to try and get back up to speed with the new advancements in .NET 3.5 as they related to WPF. There has been a lot of hype about the benefits of WPF, but from an outside view all I had seen were some basic examples, noting that would make me think it was for a serious business environment.

So I decided the best way to learn WPF was grab a few books. I purchased this title and one other. I stated on the other as it has flash color pictures though it was only half the size. I put it down half way through and moved on to this book and have not looked back.

The content is far better organised, has more depth, better examples and is generally just better structured. The author walks through each topic logically and builds up from the basics to more complex and complete examples as they take you through the chapter.

If I was to only buy one book on the topic, so far this would be it. As a programmer with years of experience, I don't find it treating me like a fool. At the same time, it guides you through the learning process so on the more experienced topics you don't feel out of depth.

Definitely the book to buy!

Grant Christensen
27 June, 2009


Great Book For WPF

This book is well written and by far the best resource I've read about WPF. I also bought "MCTS 70-502 Training Kit" for my MCTS preparation, but that book is not as complete as this book. Believe me, Matthew MacDonald really did a great job!

Anton Setiawan
25 June, 2009


Best I've seen on WPF

Pro WPF in C# 2008: Windows Presentation Foundation with .NET 3.5, Second Edition (Books for Professionals by Professionals)

I've been trying for 6 months to gleen the basics of WPF from articles on various websites. I'd just like to chime in that I've learned more about WPF in the first 50 pages of Matthew MacDonald's book than in the 6 months of browsing articles penned by the experts. Thanks to Matt, I can actually foresee myself using WPF for serious work in the very near future.

Thanks, Matt!

Duane Doutel
04 June, 2009


Comprehensive and reads like a manual

This book comprehensively covers the topic of WPF, almost to a fault. It reads a bit like a manual at points and tries to venture off subject many times and explain basic UI design principles. I would rather have seen a focus on WPF specifically without all of the banter, but others might like the historical perspective, especially if they are new to UI design in general.

All-in-all it is a good desk reference, but not a cover-to-cover read.

M. Shiffer
26 May, 2009


Excellent Material

The writer is clearly not only an expert in his field but also understands how to convey his knowledge with clarity.

A. H. Veldhuizen
10 May, 2009


Almost every thing about WPF

If you think Winform is good enough.. you are either too old or to too lazy or both. I feel Mat has done a great job of keeping the book straight and to the point. Very focused approach to WPF. Although I feel there should have been a bit more on DrawingVisual and its hidden wonderland of raw performance. It's a great book to read and work with from cover to cover, although I use it as a reference too.

Vinay K. Sharma
16 April, 2009


A Must Have Book for WPF

I purchased the book "Pro C# 2008 and the .NET 3.5 Platform" also from Apress (which is also an excellent book) to learn about .NET 3.5. The three chapters in that book on WPF was just enough to whet my appetite. I needed something that went deeper into WPF. I purchased this book based on the other reviews. This book is great at covering the subject both on a practical level and on an in-depth under the hood level. It has helped to answer many of the questions I had on how WPF does what it does.
There are definitely parts that are way over my head. But that's not a bad thing. As I continue working with WPF and gain further insight into it's functionality and working, I can return to the book and pick up the things I don't understand now. This means that it's a great book to have at a beginner level and also still a valuable resource for those that have been using WPF for a couple years. Thanks for the book!

Bryan Campbell
13 February, 2009


Great reference for WPF

This is a great reference for WPF--I've been looking for a book like this for quite a while. It's probably not the best learning resource, but once you have a general understanding of WPF, this book can help dig deeper into specific topics, like "How do I change the startup behavior of a WPF apoplication? Can I put my UI files into a DLL, so I can swap the UI?" Chapter 3 helps answer both questions. No hesitation recommending this book to intermediate-level WPF developers.

David C. Veeneman
22 November, 2008


Very thorough, but not clear for learners

This is certainly a thorough book, at 1000 pages highly suitable for thumping down on tables in order to impress people with the kinds of arcane stuff you get into. There are an awful lot of gotchas in WPF for the newbie, and one of the strengths of this book is that it has lots of detail about these unexpected behavioral quirks that would otherwise have you tearing your hair out and swearing at your innocent monitor. However, as a learning tool for someone who knows nothing about WPF - surely most of its likely readership - it isn't the clearest or easiest read. Compare it to a truly excellent technical book like my all-time favorite Albahari's "C# in a Nutshell": Albahari starts with simple topics, clearly explained, and gradually progresses to the more difficult and obscure. Macdonald starts his explanation of Dependency Properties with how you create your own ones in .NET: a complicated operation which I for one had no interest in at that point, since I didn't even get what they were yet!
Same story with Control Templates: we get the whole stuff about visual trees before we get to see a simple example. Most of the time, we developers try to start by *doing* something with the technology, before we worry too much about the arcana of how it all hangs together under the hood. More grievously though, Macdonald doesn't actually explain how one's newly created control template is applied to an actual control. I guess one is assumed to be able to work out something so obvious for oneself! All his examples show control template markup, but nothing about how they get applied to the control they are templating. Sure, it's easy once you know, and you can see how it's done in the downloadable code for the book, but something so fundamental should be explained in the text, and right at the start.

I don't know if the better-known Applications=Markup+Code does a better job as a tutorial, so I can't tell you to buy something else, but to be honest I'm sort of wishing I had.

Pierz Newton-John
11 November, 2008


Great book! Better than WPF Unleashed!!

I ordered this book and WPF Unleashed (Adam Nathan) at the same time. I read WPF Unleashed first because I saw the reviews on Amazon.com. Then I read this title, Pro WPF in C# 2008.

I found this to be a much better book than WPF Unleashed. It's thicker, has more content, and dives much deeper. Don't get me wrong, they are both excellent books and I recommend them both. But if you really want to understand core WPF concepts, this book is the better choice.

J. S. Cox
14 October, 2008


Very nice

Really a very nice introduction to WPF, it includes all the details to include win32 controls in WPF windows and WPF controls in WinForms app. I definitaly recommend this book!

Alberto Bencivenni
13 October, 2008


Best technical book I've read in a while

This book is laid out in a clear, straight-forward way. The chapters, and content within each, flow well. There is so much to learn with WPF, evidenced by the size of this book, that it can be daunting. However, Matthew takes a pragmatic, step-by-step approach which makes it very digestible. On numerous occasions I've found myself learning something in a paragraph but coming up with questions, only to find answers to those exact questions in the following paragraphs.

I just searched and see that the author is writing a Silverlight 2 book. Sign me up!

G. Chamberlain
08 October, 2008


A must have for serious WPF users

What makes developers who migrate from WinForms, MFC, etc. excited on WPF is the plenty of paths that goes to the customization of built-in/user-defined controls.

This book covers all aspects of control customization clearer than any other online article, or book on WPF that I've read.

It's initially my primary source of information on WPF, as it has a broad coverage of topics with a well defined scope.

Aykut KiliƧ
24 September, 2008


Very helpful

So far, I've found Pro WPF to be a decent reference and a very good overview of WPF. I was particularly interested in the chapter on text layout, which was good but not great. I would have appreciated it if that chapter was a little more in depth, but it's still the best treatment of fixed and flow documents that I have found.

J. D. Bannon
02 September, 2008


Excellent reference but can be difficult to wade through at times

This is the book to get if you want expert guidance on, say, how to leverage WPF features to give your user interface controls a different look and feel because the author provides plenty of substantive examples and even covers some features not documented well elsewhere. If you're looking, however, for guidance of the more "architectural" kind such as what WPF facilities and techniques will help you implement modern day variants of the Model View Controller design pattern such as MVP or MVVM, you will not find it in this book. Also, this is probably not a book that you can (or will) read from cover to cover in a few sittings because some of the scenarios covered may not be applicable to you right away in that they're fairly advanced or don't occur frequently, so be forewarned: this book can be difficult to wade through at times. But overall, an excellent reference!

Techie Evan
09 August, 2008


Saved Me Many Many Times

I love the Petzold book Applications = Code + Markup, but it covers a subset of WPF and is out of date now. Pro WPF in C# 2008 is up-to-date, covers a much larger subset, and doesn't shy away from the hard stuff. Almost every time I turn to this book, I find either an answer or a new pointer that leads to the answer on-line. Yesterday, I found a method called TemplatedParent that is ill-covered in my other books. Today, I found IScrollInfo. Highly recommended as a well-written, comprehensive, up-to-date WPF reference for intermediate to advanced developers. For starting out, I still recommend the Petzold book, which really tries hard to build understanding.

Dale A. Barnard
25 June, 2008


I wish i could give it 4 star, but...

I generally like Matthew's writing, but this one really fell short of my expectations, esp considering it's a 2nd edition (I've never read the first edition, though).

Pros:
- it gave a good overview of what WPF is all about(the underlying DirectX etc), and why we need yet another Windows GUI technology.

Cons:
- it lacks substance, each chapter mostly contains a shallow description of a "feature" of WPF, with some code snippets. The content feels more like a showoff of what WPF can do + some tips & tricks.

- there is no central theme in the book, ie. the author doesn't hold your hand and build a non-trivial app using the key features of WPF. So at the end of the book, i'm still at a loss as to how to re-write some of my Windows Forms apps in WPF.

- it's completely focused on the WPF technology, with hardly any information on the fundamentals of Computer Graphics theory and how it's related to WPF. I guess for most folks who just want to cobble togther a form with a few data bound controls in it, this prob isn't a problem. But to create commercial apps in WPF, this book is just not enough.

W. WEI
04 June, 2008


Good so far

The book is good so far. Only about 150 pages into the book, but so far easy to read, examples range from simple to more advanced. I will post another review upon completion.

Jeffrey T. Littlejohn
23 April, 2008


A great way to learn WPF

I've bought three books about WPF, including Windows Presentation Foundation Foundation Unleashed and Silverlight 1.0 Unleashed. Matthew MacDonald's book is for developers and is what I needed. It uses Visual Studio 2008 and is up to date with current development tools. I've also read his books on ASP.NET and this is one top-notch author. I fully recommend this book.

Charles J. Jurczak
11 April, 2008


WPF is next great Web/Winform Standard

Please buy this book if you haven't explored Windows Presentation Foundation. The separation of the UI (with XAML) and the code-behind page controller (C# or VB.NET) will revolutionize .NET development. If you don't have a designer you must learn Microsoft Expression Blend, but a UI designer will push your view (from Model-View-Controller) to the extreme.

The browser-based XBAP works like a Winform app, but it can be viewed in Internet Explorer. If you've ever tried to create a dirty flag to denote changes in form data in ASP.NET, you know how superior Winforms are for this purpose. XBAPs give you the ability to access the textbox text changed event like Winforms. This takes a ton of JavaScript to accomplish the same programming task in ASP.NET forms.

The update of the application to the client machine (the XBAP runs on the client) can be done with new technolgy called ClickOnce. What a technology!

I've even tried to learn the XAML markup from a very good chapter on this.

This book is really well done. Kudos to the author.

Franc Stratton
19 March, 2008


I highly recommend the book...

I have the first edition of this book (Pro WPF: Windows Presentation Foundation in .NET 3.0), so I was hesitant in buying this version. WPF 3.5 did not have major feature upgrades from 3.0. I am glad that I did buy it, but I can't really recommend doing so for other people with the .NET 3.0 version, only because there is not that much new material.

However, I highly recommend the book if you don't own the previous edition. I also highly recommend it even if you have the first one and you are like me and pretty much trashed my first edition copy. It has been through several storms and has a lot of notes and ink running all over it. So it is nice to have a new copy to beat the crap out of. I also like having the latest information I am using up to date.

Here is what is new in this release:
--Firefox support for XBAPs.
--Data binding support for LINQ.
--Data binding support for IDataErrorInfo.
--Support for placing interactive controls (such as buttons) inside a RichTextBox control.
--Support for placing 2-D elements on 3-D surfaces.
--An add-in model.

Matthew has added content for all the topics listed above.

Some of the highlights of the book I like:
--His in-depth coverage of printing.
--His Custom Elements chapter.
--The new chapter on Application Add-Ins.
--The chapter on using ClickOnce with WPF.
--Everything is gone into in depth. This is not a brush over the topic book.
--The usability of the code makes the book all that much more valuable.

The book focuses on WPF only. It has a few pages on LINQ, but that is about it as far as the rest of the .NET 3.5 framework goes. In other words, the book does not cover how to best use WPF in relationship to WCF, WF, or LINQ. This does not take anything away from the book because Matthew does not claim that the book does this. I only mention it because his ASP.NET 3.5 book does go into LINQ application integration.

The downloadable code is very well organized and is very usable.

I highly recommend this book to anyone getting into WPF with .NET 3.5.



T. Anderson
14 March, 2008