diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2009-12-01 23:48:47 -0800 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2009-12-01 23:48:47 -0800 |
commit | c3fa77496617b84a6eb751fc80d556b4b898bd50 (patch) | |
tree | 2273b2099cc87f3149b2145b59eea6a6baa3e18c /samples/OpenIdOfflineProvider/MainWindow.xaml.cs | |
parent | bc6714786258281d9f144f96e795d06c31a16846 (diff) | |
parent | 7c1d657f7a81bf628298d37246dcb4165473738f (diff) | |
download | DotNetOpenAuth-c3fa77496617b84a6eb751fc80d556b4b898bd50.zip DotNetOpenAuth-c3fa77496617b84a6eb751fc80d556b4b898bd50.tar.gz DotNetOpenAuth-c3fa77496617b84a6eb751fc80d556b4b898bd50.tar.bz2 |
Merge branch 'v3.2' into v3.3
Diffstat (limited to 'samples/OpenIdOfflineProvider/MainWindow.xaml.cs')
-rw-r--r-- | samples/OpenIdOfflineProvider/MainWindow.xaml.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/samples/OpenIdOfflineProvider/MainWindow.xaml.cs b/samples/OpenIdOfflineProvider/MainWindow.xaml.cs index f4f88ca..8f04da3 100644 --- a/samples/OpenIdOfflineProvider/MainWindow.xaml.cs +++ b/samples/OpenIdOfflineProvider/MainWindow.xaml.cs @@ -13,6 +13,7 @@ namespace DotNetOpenAuth.OpenIdOfflineProvider { using System.IO; using System.Linq; using System.Net; + using System.Runtime.InteropServices; using System.Text; using System.Windows; using System.Windows.Controls; @@ -162,7 +163,11 @@ namespace DotNetOpenAuth.OpenIdOfflineProvider { /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.Windows.Input.MouseButtonEventArgs"/> instance containing the event data.</param> private void opIdentifierLabel_MouseDown(object sender, MouseButtonEventArgs e) { - Clipboard.SetText(opIdentifierLabel.Content.ToString()); + try { + Clipboard.SetText(opIdentifierLabel.Content.ToString()); + } catch (COMException ex) { + MessageBox.Show(this, ex.Message, "Error while copying OP Identifier to the clipboard", MessageBoxButton.OK, MessageBoxImage.Error); + } } } } |