Interview questions: WPF Developer

Viewed 70232

What should every WPF developer know?

Entry Level

  • Strong .NET 2.0 Background & willing to learn!
  • Explain dependency properties?
  • What's a style?
  • What's a template?
  • Binding
  • Differences between base classes: Visual, UIElement, FrameworkElement, Control
  • Visual vs Logical tree?
  • Property Change Notification (INotifyPropertyChange and ObservableCollection)
  • ResourceDictionary - Added by a7an
  • UserControls - Added by a7an
  • difference between bubble and tunnel routing strategies - added by Carlo
  • Why did Microsoft introduce yet another markup language?
  • XAML

Mid-level

  • Routed Events & Commands
  • Converters - Added by Artur Carvalho
  • Explain WPF's 2-pass layout engine?
  • How to implement a panel?
  • Interoperability (WPF/WinForms)
  • Blend/Cider - Added by a7an
  • Animations and Storyboarding
  • ClickOnce Deployment
  • Skinning/Themeing
  • Custom Controls
  • How can worker threads update the UI?
  • DataTemplate vs HierarchicalDataTemplate
  • ItemsControl vs ItemsPresenter vs ContentControl vs ContentPresenter
  • Different types of Triggers

Senior

  • Example of attached behavior?
  • What is PRISM,CAL & CAG?
  • How can worker threads update the UI?
  • WPF 3D - Added by a7an
  • Differences between Silverlight 2 and WPF
  • MVVM/MVP - Added by a7an
  • WPF Performance tuning
  • Pixel Shaders
  • Purpose of Freezables

Any other "trick" questions to ask?

Do you expect your WPF developer to know blend?

20 Answers

I'm surprised no one has mentioned basic knowledge of XAML yet. Knowing what XAML is, and the ability to do some basic editing using XAML rather than a graphical design tool. Mid-level developers should be able to knock up form / graphic prototypes using a tool like XAMLPad.

Personally I would sit them down in front of a standard developer build machine and ask them to complete some task. No questions, just see what their code is like after a couple of hours (or more if the task is longer).

I have had a zero failure rate on making a hiring descision based on the results of an actual real life programming test.

The task doesn't have to be too difficult. I've used a simple message of the day application in the past with the messages being held in a database or XML file and a simple user interface. Ensure you ask them to structure it well (as the task is sufficiently small that it could all be done in one class if they felt inclinded).

Of the questions above I'd say you cannot get a good idea of whether they are really any good or not. A potential candicate could actually just read these and create canned answers that sound great. All this shows is that the candidate can talk-the-talk, but what matters in the job itself is if they can walk-the-walk.

I'd put binding and converters at entry level, since that is how you spend a lot of time in WPF.

Pretty good list in my opinion.
However I wouldn't ask tricky questions on interview. Interview gives enough stress itself, trick question can confuse even highly skilled person.

Personally, I'd put 'How can worker threads update the UI' right under entry-level. Mid-level, if you really need to. If an entry-level programmer can understand the difference between the logical tree and the visual tree, they should understand how to update the UI from a background thread.

At my organization, we do a lot of WPF development without Blend. I don't particularly like Blend, so I'm a bit biased, but Blend skills should be a nice-to-have, I think.

A WPF developer should have a firm grasp of separating the XAML from the code-behind, and be able to discuss at length where that line is to be drawn.

Being able to set up a model in the language of her choice, and then using XAML to display views on that model through data binding, data templates, control templates, styles, triggers, value converters and UserControls is a fairly basic task for the mid-level programmer. (Though a small amount of leeway should be granted if asking someone to create something like a control template "from heart.")

Really, there is a lot in WPF, and if it weren't for the MSDN forums and in-depth books on the subject, it'd be quite the task to "just pick it up." For that reason, I would rate perseverance and the ability to learn from others as a top requirement for any level.

For an entry-level WPF programmer, I wouldn't expect any knowledge of WPF per se, but I would demand knowledge of object-oriented principles, separation of UI from business logic, and comfort with a similar event model. Experience laying out UI elements in a style similar to WPF (with DockPanel containers, etc.) is a plus.

Edit: Also, what Colin Mackay said.

What about GUI programming/graphics experience in general and cs knowledge? If it's for a full time jobs, it does not matter IMHO if the guy has to spend the first few months some time with learning WPF, if he (or she) has a strong background.

Entry Level

  • Property Change NOtification (INotifyPropertyChange and ObservableCollection)
  • ResourceDictionary
  • UserControls

Mid Level

  • Blend/Cider
  • animations and storyboarding
  • ClickOnce Deployment

Senior

  • WPF 3D
  • Differences between Silverlight 2 and WPF
  • MVVM/MVP
  • WPF Performance tuning
  • Pixel Shaders
  • What is the relationship between threads and Dispatchers?
  • What is the purpose of Freezables?
  • What is the difference between properties and Dependency Properties? Why use one or another?
  • Converters(simple and multi).
  • Interoperability.

I think I would prefer a dev that would know Blend. He/She could communicate easily with the designer and also do some basic designer stuff faster than just writing in xaml.

The list is interesting, maybe links to the topics would help.

Cheers

Mid or maybe Senior: WinForms and WPF InterOp.

Mid or maybe Senior

  • Skinning/Themeing
  • Custom Controls
  • DataTemplate vs HierarchicalDataTemplate
  • ItemsControl vs ItemsPresenter vs ContentControl vs ContentPresenter
  • Different types of Triggers
  • How to do Animations through StoryBoards

I think lifecycle of WPF application - from creation to runtime should be included in the Beginner level of questions. Without knowing it, its hard to believe one is a real WPF dev.

I'd extend the ClickOnce deployment with WPF Deployment in general, since it's good to know the limitations and peculiarities of each model (ClickOnce, XBAP, browser only). Placing it at mid-level seems fair though.

Related