Exemplo n.º 1
0
        private void ShowAlertMessage(ScrumFactory.Exceptions.ScrumFactoryException ex)
        {
            if (!ex.IsLocalized)
                ex.LocalizeException(Properties.Resources.ResourceManager);

            string exceptionType = ex.GetType().ToString().Replace('.', '_');
            string imageSource = Properties.Resources.ResourceManager.GetString(exceptionType + "_errorImageSource");
            if (imageSource != null)
                AlertMessageViewModel.ImageSource = Properties.Resources.ResourceManager.GetString(exceptionType + "_errorImageSource");
            else
                AlertMessageViewModel.ResetErrorImage();

            AlertMessageViewModel.Title = ex.LocalizedMessageTitle;
            AlertMessageViewModel.Message = ex.LocalizedMessage;

            ShowTopMenu = true;
            AlertMessageViewModel.Show();
        }