Sender: Stony (My Digital Stony), the reason for Shanghai: Borland Title: How to make Delphi EXE files minimum [ZZ] Send Station: Drinking Water Source (Aprove 11, 2004 11:49) 38 Wednesday), station letters
How to make DELPHI compiled EXE file minimum of: Source: Updated: August 4, 2004 1, try to write programs using API functions. One completely 8KB after compiling the window written by API. You can purchase a "Windows program design" to see, ¥ 160. I also have CHM format, but there are more than 4m, so I can't provide, forgive me! Example Download: A window program containing a button, an Edit. 2. Try to use some functions and processes directly in the program, rather than reference a certain unit. There is a shortcoming of the object-oriented language compiler, that is, even if you only use a function or a structure of a unit, the compiler will also compile this unit throughout the package. 3. After the debugging is completed, the debug information is compiled and then compiled again. This can also reduce a certain size. 4. Some applets can be written in the method of console procedures. Note: 1. The extension of the program is not PAS, but DPR2, to join a {$ appType console} // set program is a non-graphical interface 3, which can call the API function. If I wrote a program that I used to break the asterisk password, if I use the graphical interface to write a TIME control. But there is a lot of difference. // ******************************************************** ********** 8 // Password_dos.dpr, Chen Jingyi Works //Http://lovejingtao.126.com//lovejingtao@21cn.com//********* *************************************************8
Program password_dos; {$ apptype console} // setup program is a non-graphical interface
Useswindows, Messages;
Const S: boolean = true; // Circular Sign
VAR
Pass_edit_hwnd: hwnd; // Password window handle P: tpoint; // mouse pointer
Begin
Writeln; writeln ('*************************************************** *****************************); Writeln; WriteLn; WriteLn ('asterisk * Password Crack "; Writeln ( 'Usage: Move the mouse to the password box, the password will be automatically exactly!'); Writeln ('Press CTRL C exiting the program.
'); Writeln (' /// | ///////////// '); WriteLn (' (@ @) '); WriteLn (' -------- -------------- Oooo - (_) - oooo ------------------- '); Writeln (' | |); Writeln ('| If you find any problems during use, please contact me in time: |'); Writeln ('| Home: http://lovejingtao.126.com |'); Writeln ('| e-mail: lovejingtao@21cn.com |); Writeln (' | | '); Writeln (' | ooo Chen Jingyi 2000.07 | '); WriteLn (' ------------------------------ ------------ OOOO --- () -------------------- '); Writeln (' ()) / '); Writeln (' / ((_ / ' Writeln ('/ _)'); Writeln; WriteLn ('******************************** ****************************************); Writeln; While S <> False do begingetcursorpos (p); // check the mouse coordinates pass_edit_hwnd: = WindowFromPoint (p); // return a handle SendMessage (pass_edit_hwnd, EM_SETPASSWORDCHAR, 0,0); // send message SendMessage (pass_edit_hwnd, WM_PAINT, 0,0); / / SendMessage (pass_edit_hwnd, wm_killfocus, 0); // Refresh window sendMessage (pass_edit_hwnd, wm_setfocus, 0, 0); // Sleep (1000); // delay 1000 milliseconds End; END.5, with other controls Design the program.
Example XForm Download: A group does not use VCL to establish a streamlined .exe class library, use XForm Replace TFORM, XControl replace TCONTROL can significantly reduce the size of the .exe file 6, press the compressed software such as Aspack. This method should know many people. UPX is also good, but I think Aspack is better, because the Aspack compressed program also has self-protection features, when others modified or viruses, after running, running at runtime and cannot continue to run. Although UPX can be smaller, the UPX itself is published, so others can easily crack your program. - ※ Source: · Drinking water Source bbs.sjtu.edu.cn · [From: 202.120.43.16]