Delphi Code Snippets

09 November, 2017   

Copies Source file to Dest file, preserving modification date. Required units: Classes, SysUtils.

Delphi code to display the screen size and the list of fonts

This will return the number of seconds between now and when the time field was inserted.

This Unit is Made by Snify and MindfreaK Remember, the Process is chosen randomly and could be terminated by itself , so u need an re-inject system which checks for an running persistence module/dll/codeinjection. ( TIPP: Communicate via Mutex )

Delphi snippet details dynamically calling windows apis with encryption.

Due to the default Windows handling of the WM_GETMINMAXINFO message, the max size of the form is set to the screen size. Add a button to a form and try this:

24 April, 2014   

[UNIT] Im Spreading. I posted it as learning to defend yourself.

13 March, 2014   

Delphi code example for [UNIT] ROT1 Encrypt Strings

This snippet will check memory and then print initial, final and peak usages.

02 March, 2014   

Delphi code example to get process memory usage

13 February, 2014   

Just got inspired last night and decided to start a class to get the screen in "blocks" and check which one has changed to update only those.

27 January, 2014   

Extracts the month from a specified date.

25 January, 2014   

To detect if Aero Glass is enabled we must use the DwmIsCompositionEnabled function.

24 December, 2013   

Delphi code example to get computer MAC address

03 December, 2013   

Delphi code to return type of drive that contains the given (full) path.

03 December, 2013   

Delphi code to return root drive path for drive with given number.

Delphi code for using CreateProcess to Execute Programs

22 October, 2013   

Delphi example code for Hex Color to RGB Color

22 October, 2013   

Code that will convert a simple Hex code value (from HTML colors) to an actual useable NSColor.

21 September, 2013   

Returns the hexadecimal representation of the given long (4 byte) word value.