NAnt SDK Documentation - v0.92 |

# ManagedAssemblyReference.ResolveAssemblyReference Method

Resolves an assembly reference.

[Visual Basic]
Overrides Protected Function ResolveAssemblyReference() As String
[C#]
protected override string ResolveAssemblyReference();

#### Return Value

The full path to the resolved assembly, or a null reference (Nothing in Visual Basic) if the assembly reference could not be resolved.

#### Remarks

Visual Studio .NET uses the following search mechanism :

1. The project directory.
2. The directories specified in the "ReferencePath" property, which is stored in the .USER file.
3. The .NET Framework directory (see KB306149)

4. The directories specified under the following registry keys:

   - HKLM\SOFTWARE\Microsoft\.NETFramework\AssemblyFolders
   - HKCU\SOFTWARE\Microsoft\.NETFramework\AssemblyFolders
   - HKLM\SOFTWARE\Microsoft\VisualStudio\<major version>.<minor version>\AssemblyFolders
   - HKCU\SOFTWARE\Microsoft\VisualStudio\<major version>.<minor version>\AssemblyFolders

   Future versions of Visual Studio .NET will also check in:

   - HKLM\SOFTWARE\Microsoft\.NETFramework\AssemblyFoldersEx
   - HKCU\SOFTWARE\Microsoft\.NETFramework\AssemblyFoldersEx
5. The HintPath.

#### See Also

ManagedAssemblyReference Class | NAnt.VSNet Namespace