Chapter 29. Navigation

 

This chapter covers

  • Browser navigation
  • The Navigation Application template
  • Navigation with out-of-browser applications

When you first created a Silverlight 2 application, you ended up with a project that contained a single white main page, probably sized at 300 x 400, depending on the template you used. There was no guidance for structuring your application or how to move from page to page. Unlike HTML pages, WPF, or Windows Forms, the navigation structure wasn’t something intuitive, building on a decade or more of knowledge and established patterns. Instead, most new Silverlight developers were left staring at that blank page, wondering what to do next.

Silverlight 3 introduced not only a complete navigation framework but also an application template built on this framework. The navigation framework takes a modern browser-oriented approach to navigation, supporting concepts such as journal histories, back-and-forward navigation, and uniquely addressable pages. This framework addressed the needs of both application structure and end-user navigation.

This chapter dives deep into Silverlight navigation. I’ll look to history to show you how navigation is handled in the browser and how hashtags or URI fragments work. From there, you’ll start building an application using the navigation template. The navigation template will then be used to explore navigation to individual pages and customization of navigation.

29.1. Browser navigation background

29.2. The Navigation Application template

29.3. Navigating to pages

29.4. Navigation out of the browser

29.5. Summary