silverlight - How to change TextBox border color programmatically

how to set change TextBox border brush (color) programmatically in silverlight
MainPage.xaml

<UserControl 
    x:Class="SilverlightApps.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    d:DesignHeight="600" 
    d:DesignWidth="800" 
    xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"
    >

    <Grid x:Name="LayoutRoot" Background="White">
        <Rectangle
            Name="rectangle1"
            Fill="AliceBlue" 
            HorizontalAlignment="Left" 
            Height="82" 
            Margin="20,12,0,0" 
            Stroke="Black" 
            VerticalAlignment="Top" 
            Width="600"
            StrokeThickness="0"
            />

        <TextBlock 
      Height="82" 
      HorizontalAlignment="Left" 
      Margin="20,9,0,0" 
      Name="textBlock1" 
      Text="how to set change TextBox border brush (color) programmatically in silverlight"
      VerticalAlignment="Top"
      TextWrapping="Wrap"
      FontSize="20"
      FontStyle="Italic"
      Foreground="MidnightBlue"
      Width="600"
      FontFamily="Comic Sans MS"
      Padding="25,10,10,0"
            />

        <TextBox 
            Name="TextBox1"
            HorizontalAlignment="Left" 
            Margin="20,140,0,0" 
            TextWrapping="Wrap" 
            Text="textbox1 for test border color" 
            VerticalAlignment="Top" 
            Width="332"
            Background="Khaki"
            FontSize="20"
            FontFamily="Comic Sans MS"
            BorderThickness="2"
            />

        <TextBox 
            Name="TextBox2"
            HorizontalAlignment="Left" 
            Margin="20,211,0,0" 
            TextWrapping="Wrap" 
            Text="textbox2 for test border color" 
            VerticalAlignment="Top" 
            Width="332"
            Background="Khaki"
            FontSize="20"
            FontFamily="Comic Sans MS"
            BorderThickness="2"
            />

        <TextBox 
            Name="TextBox3"
            HorizontalAlignment="Left" 
            Margin="20,270,0,0" 
            TextWrapping="Wrap" 
            Text="textbox3 for test border color" 
            VerticalAlignment="Top" 
            Width="332"
            Background="Khaki"
            FontSize="20"
            FontFamily="Comic Sans MS"
            BorderThickness="3"
            />

        <Button 
            Name="Button1"
            Content="Change TextBox Border Color" 
            HorizontalAlignment="Left" 
            Height="33" 
            Margin="420,140,0,0" 
            VerticalAlignment="Top" 
            Width="200" 
            Click="Button1_Click"
            />
    </Grid>
</UserControl>
MainPage.xaml.cs

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace SilverlightApps
{
    public partial class MainPage : UserControl
    {
        public MainPage()
        {
            InitializeComponent();
        }

        private void Button1_Click(object sender, RoutedEventArgs e)
        {
            SolidColorBrush scb1 = new SolidColorBrush(Color.FromArgb(255, 255, 20, 147));
            SolidColorBrush scb2 = new SolidColorBrush(Color.FromArgb(255, 149, 69, 19));
            SolidColorBrush scb3 = new SolidColorBrush(Color.FromArgb(255, 189, 183, 107));

            TextBox1.BorderBrush = scb1;
            TextBox2.BorderBrush = scb2;
            TextBox3.BorderBrush = scb3;
        }
    }
}
More silverlight examples