比如下面一段简单的代码program Project3;uses
  FastMM4,
  Forms,
  Unit2 in 'Unit2.pas' {Form2};{$R *.res}begin
  Application.Initialize;
  Application.MainFormOnTaskbar := True;
  Application.CreateForm(TForm2, Form2);
  Application.Run;
end.即使这么简单的代码依然报错
[DCC Error] Project3.dpr(6): F1026 File not found: 'FastMM4.dcu'不知道为什么,请各位指教。在公司的机器上可以,在自己的笔记本上却不行。

解决方案 »

  1.   

    在library中把这个FastMM4.dcu 的路径添加进来,再编译看看
      

  2.   

    tools->options->library->library path添加FastMM.pas所在路径即可
      

  3.   

    Tools->Environment Options 的Library页中的Library path
      

  4.   


    $(BDS)\lib;
    $(BDSUSERDIR)\Imports;
    $(BDS)\Imports;
    $(BDS)\Lib\Indy10;
    $(BDSCOMMONDIR)\Dcp;
    $(GRS)\Lib;$(GRS)\Lib\D10;
    $(GRS)\Lib\Res;
    $(GRS)\GrandSoft\Extended\Source;
    $(GRS)\GrandSoft\GrandCommon\Source;
    $(GRS)\GrandSoft\GrandCommon\Source\LZMA;
    $(GRS)\GrandSoft\GrandDog\Common;
    $(GRS)\GrandSoft\GrandReport\Report30\Common;
    $(GRS)\GrandSoft\GrandReport\Report40\Common;
    $(GRS)\GrandSoft\GrandSmartPlatform\Common;
    $(GRS)\GrandSoft\GrandSmartPlatform\Common_Inner;
    $(GRS)\GrandSoft\GrandSmartPlatform\Explorer;
    $(GRS)\GrandSoft\GrandSmartPlatform\Report;
    $(GRS)\GrandSoft\GrandWorkflow\Source;
    $(GRS)\GrandSoft\VectorDrawEditor\Source\Units;
    $(GRS)\External\ASProtect;
    $(GRS)\External\DUnit\Source;
    $(GRS)\External\Jcl\source\common;
    $(GRS)\External\Jcl\source\windows;
    $(GRS)\External\Synapse\Source;
    $(GRS)\External\TeeChart\Source;
    C:\Program Files\Raize\RC4\Lib\BDS2006;
      

  5.   

    http://blog.csdn.net/akof1314/article/details/6524767
      

  6.   

    FastMM4不是官方的内存管理器.所以需要先下载然后才能用.http://fastmm.sourceforge.net
      

  7.   

    FastMM是检查内存泄露用的,注释掉也不影响程序编译,如下:uses
    //  FastMM4, //注释掉这里
      Forms,
      Unit2 in 'Unit2.pas' {Form2};
    当然,按楼上的方法添加查找路径或下载FastMM的源码装上也可以。
      

  8.   

    晕,fastMM4的位置写错了,无比尴尬
    但是还是按照二楼的办法引用了下载的fastMM4
      

  9.   

    发现fastMM的位置写错了,无比尴尬
    但是引用了二楼的方法
      

  10.   

    FastMM不光是检测内存泄露的,他可以完全替代Delphi自己的内存管理器(前提是工程文件uses的第一个),效率比原始的高出好多。虽然在BDS 2006 以后Delphi就使用了FastMM,但我还是喜欢用最新稳定版。注释掉就实用默认的delphi内存管理器,没任何影响,不要求效率的基本感觉不出来。