Index: DamEngine/trunk/src/Deltares.DamEngine.Interface/FillXmlInputFromDam.cs =================================================================== diff -u -r3651 -r3864 --- DamEngine/trunk/src/Deltares.DamEngine.Interface/FillXmlInputFromDam.cs (.../FillXmlInputFromDam.cs) (revision 3651) +++ DamEngine/trunk/src/Deltares.DamEngine.Interface/FillXmlInputFromDam.cs (.../FillXmlInputFromDam.cs) (revision 3864) @@ -315,48 +315,48 @@ { if (damProjectData.Dike == null) { - throw new NullReferenceException(Resources.NoDikeInProject); + throw new ArgumentNullException(Resources.NoDikeInProject); } if (damProjectData.Dike.Locations == null) { - throw new NullReferenceException(Resources.NoLocationsInProject); + throw new ArgumentNullException(Resources.NoLocationsInProject); } foreach (Location location in damProjectData.Dike.Locations) { if (location.Scenarios == null) { - throw new NullReferenceException(Resources.NoDesignScenariosInLocationProject); + throw new ArgumentNullException(Resources.NoDesignScenariosInLocationProject); } } if (damProjectData.Dike.SurfaceLines2 == null) { - throw new NullReferenceException(Resources.NoSurfaceLinesInProject); + throw new ArgumentNullException(Resources.NoSurfaceLinesInProject); } else { foreach (var surfaceLine in damProjectData.Dike.SurfaceLines2) { if ((surfaceLine.CharacteristicPoints == null) || (surfaceLine.CharacteristicPoints.Count < 1)) { - throw new NullReferenceException(string.Format(Resources.NoCharacteristicPointsInSurfaceLineProject, surfaceLine.Name)); + throw new ArgumentNullException(string.Format(Resources.NoCharacteristicPointsInSurfaceLineProject, surfaceLine.Name)); } if ((surfaceLine.Geometry == null) || (surfaceLine.Geometry.Count < 2)) { - throw new NullReferenceException(string.Format(Resources.NoPointsInSurfaceLineProject, surfaceLine.Name)); + throw new ArgumentNullException(string.Format(Resources.NoPointsInSurfaceLineProject, surfaceLine.Name)); } } } if (damProjectData.Dike.SoilList == null) { - throw new NullReferenceException(Resources.NoSoilsInProject); + throw new ArgumentNullException(Resources.NoSoilsInProject); } if (damProjectData.Dike.SoilList.Soils == null) { - throw new NullReferenceException(Resources.NoSoilsInProject); + throw new ArgumentNullException(Resources.NoSoilsInProject); } if (damProjectData.Dike.SoilProfiles == null) { - throw new NullReferenceException(Resources.NoSoilProfiles1DInProject); + throw new ArgumentNullException(Resources.NoSoilProfiles1DInProject); } // Check for invalid Id names