void MyTextBox_LostFocus(object sender, RoutedEventArgs e)
 {
     if (string.IsNullOrEmpty(MyTextBox.Text.Trim()))
     {
         AdornerLayer layer = AdornerLayer.GetAdornerLayer(MyTextBox);
         t = new TextBoxTipAdorner("请输入", MyTextBox);
         layer.Add(t);
     }
 }
Beispiel #2
0
 void MyTextBox_LostFocus(object sender, RoutedEventArgs e)
 {
     if (string.IsNullOrEmpty(MyTextBox.Text.Trim()))
     {
         AdornerLayer layer = AdornerLayer.GetAdornerLayer(MyTextBox);
         t = new TextBoxTipAdorner("请输入", MyTextBox);
         layer.Add(t);
     }
 }