private void OnGetRuleByNameNotFound(object sender, GetRuleByNameNotFoundEventArgs e) { object[] name = new object[1]; name[0] = e.Name; base.WriteError(new ErrorRecord(new Exception(string.Format(CultureInfo.CurrentCulture, Resources.Rule_NotFoundByName, name)), "GetRuleError", ErrorCategory.InvalidOperation, null)); }