public override void Save()
{
if (this.Id > 0 && StorageContext.Search.IsOuterEngineEnabled)
{
var query = string.Format("+Type:surveyitem +ParentId:{0} .COUNTONLY .LIFESPAN:OFF .AUTOFILTERS:OFF", this.Id);
if (ContentQuery.Query(query).Count > 0 && _originalContentListDefinition != this.ContentListDefinition)
{
throw new InvalidContentActionException("Cannot modify questions due to existing filled survey(s).");
}
}
base.Save();
}