用KOL进行开发!
用纯API进行开发!哈哈~~~~~~~~~~

解决方案 »

  1.   

    建立Console Application项目程序或者在uses里去除Forms单元
      

  2.   

    KOL我也是听说的,就是和VCL一样的一个控件集!但使用KOL开发的程序体积很少!和VC的差不多吧?听说是俄罗斯的几个老毛子开发的!~~~~~~~~~~,现在还有一个和KOL一样的控件集,叫做什么去了?????呵~~~忘记了.
      

  3.   

    如果只是追求体积小一些,还可以用压缩EXE的软件来后期加工一下.
      

  4.   

    尽量使用api,然后,把uses clause中没用到的单元都去掉-----虽然delphi方面说编译器自动把没用到的单元给去掉了,事实上我经常发现还是没去彻底。比如,一般的delphi5下的程序都在300k左右,但若只使用必要的单元如windows,messages则大小将<20!
      

  5.   

    在Project Option 中设置为运行进链接
      

  6.   

    在Project Option 中设置为运行进链接
      

  7.   

    只有不用VCL,就很小。。Delphi 5下通过,20K,
    用Fee Pascel 1.0.4,15K
    去掉{$R *.res},可以再少1K。program NoVCL;{$R *.res}uses
      Windows,
      Messages;function WndProc(Window: HWnd; AMessage,WParam,LParam: Longint): Longint; stdcall;
    begin
      Result := 0;
      if AMessage = WM_Destroy then
      begin
        PostQuitMessage(0);
        Exit;
      end;  Result := DefWindowProc(Window, AMessage, WParam, LParam);
    end;const
      ClassName = 'Pascal No Vcl';function WinRegister: Boolean;
    var
      WindowClass: TWndClass;
    begin
      with WindowClass do
      begin
        Style := CS_HRedraw or CS_VRedraw;
        lpfnWndProc := @WndProc;
        cbClsExtra := 0;
        cbWndExtra := 0;
        hInstance := SysInit.HInstance;
        HIcon := LoadIcon(0, IDI_Application);
        hCursor := LoadCursor(0, IDC_Arrow);
        hbrBackground := HBrush(Color_Window);
        lpszMenuName := nil;
        lpszClassName := ClassName;
      end;
      Result := RegisterClass(WindowClass) <> 0;
    end;function WinCreate: HWnd;
    var
      HWindow: HWnd;
    begin
      HWindow := CreateWindow(ClassName, 'Delphi', WS_OverlappedWindow, 50, 50,
                              600, 400, 0, 0, HInstance, nil);
      if HWindow <> 0 then
      begin
        ShowWindow(HWindow, CmdShow);
        UpdateWindow(HWindow);
      end;
      Result := HWindow;
    end;
    var
      AMessage: TMsg;
      HWindow: HWnd;
    begin
      if not WinRegister then
      begin
        MessageBox(0, 'Register Class Error', 'Delphi', MB_OK);
        Exit;
      end;  HWindow := WinCreate;  if HWindow = 0 then
      begin
        MessageBox(0, 'CreateWindowError', 'Delphi', MB_OK or MB_ICONERROR);
        Exit;
      end;  while GetMessage(AMessage, 0, 0, 0) do
      begin
        TranslateMessage(AMessage);
        DispatchMessage(AMessage);
      end;
    end.
      

  8.   

    yes,yes.BaldZhang,你好厉害,竟然背下来了。好!
      

  9.   

    第一:用sdk开发
    第二:用aspack压!
      

  10.   

    不过,玩笑总是玩笑其实VCL库已经做的很好了,无论是代码的质量,还是类的体系结构,都是我们学习的典范,
    对于现在的计算机来说,程序的大小已经不是考虑的重点了,关键还是功能的实现和逻辑
    的正确性,从速度上来说,我从来没有听人抱怨过Delphi写的程序慢的,再说,要相信Borland做编译器的技术啦。对于一个空白的窗体,Delphi3生成的是170K左右,到了Delphi5 就有280K左右了,一方面
    编译器里多了很多东西,另一方面VCL库也在不断扩充,如果一定要用VCL,又不是要做COM
    方面或者三层的数据库,可以考虑用Delphi3来最后编译一遍你的程序。但是3确实不如5好用啊另外,从4开始VCL支持对DockForm的支持,个人认为是个很大的败笔,机会没带来什么
    好处,还引入了很多问题,代码也多了,程序也大了。以前玩音响的时候,有一句话,叫简洁至上,用在写程序上,也没有错吧