public void UpdateElement(Document document, ElementId id) { if (document == null) { throw new ArgumentNullException(nameof(document)); } if (document.IsFamilyDocument) { PostWarningIsFamilyDocument(document, id); } else { Element foundation = document.GetElement(id); if (foundation.Location != null) { if (foundation.Location is LocationPoint locationPoint) { XYZ location = CoordinateHelper.GetWorldCoordinates(document, locationPoint.Point); UpdateParameters(foundation, location); } } } }