Ejemplo n.º 1
0
 private void ProxyOpenCommand_Execute()
 {
     if (IsOpen)
     {
         ChannelProxy.Close();
         IsOpen = false;
     }
     else
     {
         try
         {
             ChannelProxy.SetChannel(OwnerChannel != null ? OwnerChannel.Channel : null);
             ChannelProxy.Open();
             IsOpen = true;
         }
         catch
         {
             MessageBox.Show((string)Manager <LanguageCultureInfo> .StaticInstance.GetResource("#InvaliseParrentChannelError"), (string)Manager <LanguageCultureInfo> .StaticInstance.GetResource("#ErrorMsgBoxTitle"), MessageBoxButton.OK, MessageBoxImage.Warning);
             return;
         }
     }
 }