homeBlogOfADamdownloadssocial webresumecontact
Contains various stuff from André Dammeyer.
feedback
I think i am a little bit late, but these days I do some intensive learning of silverlight stuff. One of my first questions was, “how to navigate between several pages in silverlight?”. There are some solutions and samples out there, but i created my own one.
I created a class PageController that derives from List<UserControls>. The PageController manages several UserControls and offers methods like Activate(), ActivateNext() and ActivatePrevious(). It activates and deactivates these UserControls as childs of a panel.
Here is a sample of using the PageController to navigate between several pages:
private void btnPrevious_Click(object sender, RoutedEventArgs e) { this.controller.ActivatePrevious(); this.btnPrevious.IsEnabled = !this.controller.IsFirst; this.btnNext.IsEnabled = !this.controller.IsLast; } private void btnNext_Click(object sender, RoutedEventArgs e) { this.controller.ActivateNext(); this.btnPrevious.IsEnabled = !this.controller.IsFirst; this.btnNext.IsEnabled = !this.controller.IsLast; }
private void btnPrevious_Click(object sender, RoutedEventArgs e) { this.controller.ActivatePrevious(); this.btnPrevious.IsEnabled = !this.controller.IsFirst; this.btnNext.IsEnabled = !this.controller.IsLast; }
private void btnNext_Click(object sender, RoutedEventArgs e) { this.controller.ActivateNext(); this.btnPrevious.IsEnabled = !this.controller.IsFirst; this.btnNext.IsEnabled = !this.controller.IsLast; }
Download Source
Interesting for me since I am working with silverlight.
look at: SLTwitterMap
Microsoft's Opinionated Misfit Geek - 44 Silverlight Videos
Data Binding Webcast - Jesse Liberty - Silverlight Geek
Copyright © 2009 by André Dammeyer.