48 references to ThrowInvalidProject
Microsoft.Build (48)
BackEnd\Components\RequestBuilder\BatchingEngine.cs (1)
416
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation,
BackEnd\Components\RequestBuilder\TargetEntry.cs (1)
347
ProjectErrorUtilities.
ThrowInvalidProject
(_target.ConditionLocation, "TargetConditionHasInvalidMetadataReference", _target.Name, _target.Condition);
BackEnd\Components\RequestBuilder\TaskBuilder.cs (2)
727
ProjectErrorUtilities.
ThrowInvalidProject
(_taskNode.ContinueOnErrorLocation, "InvalidContinueOnErrorAttribute", _taskNode.Name, e.Message);
758
ProjectErrorUtilities.
ThrowInvalidProject
(_targetChildInstance.Location, "TaskParametersError", _taskNode.Name, String.Empty);
BackEnd\TaskExecutionHost\TaskExecutionHost.cs (1)
1123
ProjectErrorUtilities.
ThrowInvalidProject
(
Construction\ProjectMetadataElement.cs (1)
151
ProjectErrorUtilities.
ThrowInvalidProject
(parentLocation, "InvalidMetadataAsAttribute", name, parentName);
Definition\Project.cs (1)
4322
ProjectErrorUtilities.
ThrowInvalidProject
(toolsVersionLocation, "UnrecognizedToolsVersion", toolsVersionToUse, toolsVersionList);
Evaluation\Conditionals\FunctionCallExpressionNode.cs (1)
95
ProjectErrorUtilities.
ThrowInvalidProject
(
Evaluation\Conditionals\GenericExpressionNode.cs (1)
65
ProjectErrorUtilities.
ThrowInvalidProject
(
Evaluation\Conditionals\Parser.cs (2)
289
ProjectErrorUtilities.
ThrowInvalidProject
(_elementLocation, "UnexpectedTokenInCondition", _lexer.IsNextString(), errorPosition);
395
ProjectErrorUtilities.
ThrowInvalidProject
(_elementLocation, _lexer.GetErrorResource(), expression, errorPosition);
Evaluation\Evaluator.cs (2)
2152
ProjectErrorUtilities.
ThrowInvalidProject
(importLocationInProject, "ImportIntroducesCircularity", importFileUnescaped, importedBy);
2340
ProjectErrorUtilities.
ThrowInvalidProject
(importLocationInProject, "InvalidImportedProjectFile",
Evaluation\Expander.cs (26)
860
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", expressionFunction, AssemblyResources.GetString("InvalidFunctionPropertyExpressionDetailMismatchedParenthesis"));
875
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", expressionFunction, AssemblyResources.GetString("InvalidFunctionPropertyExpressionDetailMismatchedQuote"));
1045
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotExpandItemMetadata", expression, ex.Message);
1424
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", propertyBody, String.Empty);
1435
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", propertyBody, AssemblyResources.GetString("InvalidFunctionPropertyExpressionDetailMismatchedSquareBrackets"));
1457
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", propertyBody, String.Empty);
1762
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidRegistryPropertyExpression", $"$({registryExpression})", ex.Message);
2758
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotEvaluateItemMetadata", metadataName, ex.Message);
3110
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotEvaluateItemMetadata", metadataName, ex.Message);
3145
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotEvaluateItemMetadata", metadataName, ex.Message);
3178
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotEvaluateItemMetadata", metadataName, ex.Message);
3214
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotEvaluateItemMetadata", metadataName, ex.Message);
3269
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CannotEvaluateItemMetadata", match.Name, ex.Message);
3794
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionStaticMethodSyntax", expressionFunction, String.Empty);
3808
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionStaticMethodSyntax", expressionFunction, String.Empty);
3819
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionTypeUnavailable", expressionFunction, typeName);
3830
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", expressionFunction, AssemblyResources.GetString("InvalidFunctionPropertyExpressionDetailMismatchedSquareBrackets"));
3861
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", expressionFunction, String.Empty);
3893
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionMethodUnavailable", _methodMethodName, _receiverType.FullName);
3910
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionMethodUnavailable", _methodMethodName, _receiverType.FullName);
4026
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", partiallyEvaluated, ex.Message.Replace("\r\n", " "));
4097
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", partiallyEvaluated, ex.InnerException.Message.Replace("\r\n", " "));
4108
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionStaticMethodSyntax", _expression, ex.Message.Replace("Microsoft.Build.Evaluation.IntrinsicFunctions.", "[MSBuild]::"));
4114
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", partiallyEvaluated, ex.Message);
4412
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", expressionFunction, AssemblyResources.GetString("InvalidFunctionPropertyExpressionDetailMismatchedParenthesis"));
4483
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "InvalidFunctionPropertyExpression", expressionFunction, String.Empty);
Evaluation\ProjectParser.cs (2)
583
ProjectErrorUtilities.
ThrowInvalidProject
(element.GetAttributeLocation(XMakeAttributes.name), "NameInvalid", targetName, targetName[indexOfSpecialCharacter]);
635
ProjectErrorUtilities.
ThrowInvalidProject
(childElement.Location, "PropertyOutsidePropertyGroupInTarget", childElement.Name, childElement.ParentNode.Name);
Instance\ProjectInstance.cs (1)
3216
ProjectErrorUtilities.
ThrowInvalidProject
(toolsVersionLocation, "UnrecognizedToolsVersion", toolsVersionToUse, toolsVersionList);
Instance\TaskRegistry.cs (1)
1518
ProjectErrorUtilities.
ThrowInvalidProject
(elementLocation, "CouldNotFindFactory", TaskFactoryAttributeName, taskFactoryLoadInfo.AssemblyLocation);
Xml\ProjectXmlUtilities.cs (3)
72
ProjectErrorUtilities.
ThrowInvalidProject
(child.Location, "InvalidChildElementDueToDuplication", child.Name, child.ParentNode.Name);
80
ProjectErrorUtilities.
ThrowInvalidProject
(location, "UnrecognizedChildElement", name, parentName);
195
ProjectErrorUtilities.
ThrowInvalidProject
(attribute.Location, "UnrecognizedAttribute", attribute.Name, attribute.OwnerElement.Name);
XmlUtilities.cs (2)
96
ProjectErrorUtilities.
ThrowInvalidProject
(location, "NameInvalid", name, name[firstInvalidCharLocation]);
114
ProjectErrorUtilities.
ThrowInvalidProject
(element.Location, "NameInvalid", name, name[firstInvalidCharLocation]);