summaryrefslogtreecommitdiff
path: root/windows
diff options
context:
space:
mode:
Diffstat (limited to 'windows')
-rw-r--r--windows/WinUI/ToolbarItem.xaml.cs21
1 files changed, 13 insertions, 8 deletions
diff --git a/windows/WinUI/ToolbarItem.xaml.cs b/windows/WinUI/ToolbarItem.xaml.cs
index 8b77fa5f..9da9fcdf 100644
--- a/windows/WinUI/ToolbarItem.xaml.cs
+++ b/windows/WinUI/ToolbarItem.xaml.cs
@@ -111,14 +111,19 @@ namespace WinUI
private void ToolbarItem_NodeIDClicked(object sender, System.Windows.RoutedEventArgs e)
{
- try
- {
- Clipboard.SetText(nodeId);
- }
- catch (ArgumentNullException)
- {
- // tried to copy a null nodeId
- }
+ try
+ {
+ Clipboard.SetDataObject(nodeId);
+ }
+ catch (ArgumentNullException)
+ {
+ // tried to copy a null nodeId
+ Console.WriteLine("ArgumentNullException");
+ }
+ catch (Exception ex)
+ {
+ Console.WriteLine(ex.ToString());
+ }
}
private void ToolbarItem_ShowNetworksClicked(object sender, System.Windows.RoutedEventArgs e)