dtSearch Text Retrieval Engine Programmer's Reference
.NET 2-4.x MFC and CRT dependencies

How to install MFC and CRT components required by the dtSearch Engine's .NET interface

The dtSearch .NET API wrapper (dtSearchNetApi2.dll or dtSearchNetApi4.dll) requires the MFC and CRT components included with Visual Studio. To install these components, you can use Microsoft redistributable installers vcredist_x86.exe and vcredist_x64.exe. vcredist_x86.exe is required for 32-bit applications. vcredist_x64.exe is required for 64-bit applications. 

Use of incorrect versions of a vcredist*.exe will result in an "application configuration is incorrect" or "could not load file or assembly" exception when you try to run your application. 

The dtSearch .NET Standard API wrapper, dtSearchNetStdApi.dll, does not require these MFC and CRT components. 

Custom builds 

The source code to the dtSearch Engine .NET API wrapper is included with the dtSearch Engine, in the C:\Program Files\dtSearch Developer\examples\cpp folder. Therefore, you can build your own version of the API wrapper by recompiling the project with Visual Studio. In this case, the required vcredist_*.exe file would be the ones that correspond to your version of Visual Studio. 

dtSearchNetApi4.dll (.NET 4.0 and later) 

Links to the most current vcredist*.exe files are posted on the Microsoft web site here: External linkThe latest supported Visual C++ downloads 


dtSearchNetApi2.dll (.NET 2.0 and later)

Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package MFC Security Update (June 7, 2011) 

External link

Why the components are required

Unfortunately there is no way in Visual Studio to build dtSearchNetApi4.dll so it does not depend on the MFC and CRT DLLs. Because it is a mixed-mode DLL (so it can interface with both .NET and the dtSearch Engine's C++ API), it has to dynamically link both the MFC and CRT DLLs.

.NET 1.1 applications

dtSearchNetApi.dll, the dtSearch .NET API for Visual Studio 2003 only, requires MSVCR71.dll, which is included with Visual Studio .NET 2003.