From 40ab6d0f36b26f01e59989524358be4d1a969eb4 Mon Sep 17 00:00:00 2001 From: Christian Wade Date: Tue, 17 Mar 2020 20:13:41 -0700 Subject: [PATCH] TomInternalException hander --- BismNormalizer/AlmToolkit/ComparisonForm.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/BismNormalizer/AlmToolkit/ComparisonForm.cs b/BismNormalizer/AlmToolkit/ComparisonForm.cs index b80195d..ceb0567 100644 --- a/BismNormalizer/AlmToolkit/ComparisonForm.cs +++ b/BismNormalizer/AlmToolkit/ComparisonForm.cs @@ -16,6 +16,7 @@ using BismNormalizer.TabularCompare.Core; using BismNormalizer.TabularCompare.UI; using CefSharp; using CefSharp.WinForms; +using Microsoft.AnalysisServices.Tabular; namespace AlmToolkit { @@ -273,6 +274,11 @@ namespace AlmToolkit this.CompareTabularModels(); toolStripStatusLabel1.Text = "ALM Toolkit - finished comparing datasets"; } + catch (TomInternalException) + { + MessageBox.Show("TOM internal serialization error occurred. Please ensure JSON is valid tabular model metadata.", Utils.AssemblyProduct, MessageBoxButtons.OK, MessageBoxIcon.Error); + SetNotComparedState(); + } catch (Exception exc) { MessageBox.Show(exc.Message, Utils.AssemblyProduct, MessageBoxButtons.OK, MessageBoxIcon.Error);