aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.Core
diff options
context:
space:
mode:
authorRoy Ben Shabat <Roy.mail.net@gmail.com>2020-05-08 00:32:36 +0300
committerRoy Ben Shabat <Roy.mail.net@gmail.com>2020-05-08 00:32:36 +0300
commit6999f84d21c1439d87d396fd7e7380cead4d52a2 (patch)
tree2ac3a88e8d08e7cc3dda946868559151a61c88f9 /Software/Visual_Studio/Tango.Core
parent98c2921a8cf655da3962edafe91bbccc89632e6d (diff)
downloadTango-6999f84d21c1439d87d396fd7e7380cead4d52a2.tar.gz
Tango-6999f84d21c1439d87d396fd7e7380cead4d52a2.zip
Users & Roles !!
Fixed Shlomo PMR.
Diffstat (limited to 'Software/Visual_Studio/Tango.Core')
-rw-r--r--Software/Visual_Studio/Tango.Core/Commands/RelayCommand.cs11
1 files changed, 10 insertions, 1 deletions
diff --git a/Software/Visual_Studio/Tango.Core/Commands/RelayCommand.cs b/Software/Visual_Studio/Tango.Core/Commands/RelayCommand.cs
index 359574a5c..427c83749 100644
--- a/Software/Visual_Studio/Tango.Core/Commands/RelayCommand.cs
+++ b/Software/Visual_Studio/Tango.Core/Commands/RelayCommand.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -47,7 +48,15 @@ namespace Tango.Core.Commands
public virtual bool CanExecute(object parameter)
{
- return _canExecute != null ? _canExecute(parameter) : true;
+ try
+ {
+ return _canExecute != null ? _canExecute(parameter) : true;
+ }
+ catch (Exception ex)
+ {
+ Debug.WriteLine("Error on CanExecute RelayCommand\n" + ex);
+ return false;
+ }
}
public virtual void Execute(object parameter)