private void btnSerial_Click(object sender, RoutedEventArgs e) { SerialKey serialkey = new SerialKey(); serialkey.ShowDialog(); }