NAnt SDK Documentation - v0.92

TargetFunctions.HasExecuted Method 

Checks whether the specified target has already been executed.

[Visual Basic]
<Function(Name:="has-executed")>
Public Function HasExecuted( _
   ByVal name As String _
) As Boolean
[C#]
[Function(Name="has-executed")]
public bool HasExecuted(
   string name
);

Parameters

name
The target to test.

Return Value

true if the specified target has already been executed; otherwise, false.

Exceptions

Exception Type Condition
ArgumentException Target name does not exist.

See Also

TargetFunctions Class | NAnt.Core.Functions Namespace