NAnt SDK Documentation - v0.92

PathFunctions.Combine Method 

Combines two paths.

[Visual Basic]
<Function(Name:="combine")>
Public Shared Function Combine( _
   ByVal path1 As String, _
   ByVal path2 As String _
) As String
[C#]
[Function(Name="combine")]
public static string Combine(
   string path1,
   string path2
);

Parameters

path1
first path
path2
second path

Return Value

A string containing the combined paths. If one of the specified paths is a zero-length string, this method returns the other path. If path2 contains an absolute path, this method returns path2.

Exceptions

Exception Type Condition
ArgumentException path1 or path2 contain one or more invalid characters.

See Also

PathFunctions Class | NAnt.Core.Functions Namespace