# framework::get-tool-path

Gets the absolute path of the specified tool for the current target framework.

### Usage

`string framework::get-tool-path(tool)`

### Parameters

Name | Type | Description
--- | --- | ---
tool | string | The file name of the tool to search for.

### Return Value

The absolute path to tool if found in one of the configured tool paths; otherwise, an error is reported.

### Exceptions

The function will fail in any of the following circumstances:

- tool could not be found in the configured tool paths.

### Remarks

The configured tool paths are scanned in the order in which they are defined in the framework configuration.

The file name of the tool to search should include the extension.

### Examples

- Use gacutil to install an assembly in the GAC.

      <exec program="${framework::get-tool-path('gacutil.exe')}" managed="strict">
          <arg value="/i" />
          <arg file="Cegeka.HealthFramework.dll" />
      </exec>

### Requirements

Assembly: NAnt.Core (0.91.4312.0)