I am writing a custom control in Silverlight and I am having issues getting my Button to click to the Generic.xaml file. This does not work:
You have to override the OnApplyTemplate() on your custom control class (C# File).
Like this.
public override void OnApplyTemplate()
{
Button btn = GetTemplateChild("ScrollLeft") as Button;
Debug.Assert(btn != null);
}
Also, you have to make one more change in the control template in Generic.Xaml like below.
Note: I removed the Click event handler.