I\'m trying to make a simple crossword puzzle game in Silverlight 2.0. I\'m working on a UserControl-ish component that represents a square in the puzzle. I\'m having trouble wi
First, set the DataContext on the UserControl using {RelativeSource Self}:
Now you can bind the individual elements to the properties of the usercontrol:
For SL 2.0, you'll need to set the DataContext on the UserControl's Loaded event handler.
private void UserControl_Loaded( object sender, RoutedEventArgs e ) {
LayoutRoot.DataContext = this;
}