Advanced Delphi Windows / Shell / API / Graphics / OLE Programming
A simple understanding of Delphi is fine when you create applications for home use. Once you start building real-world applications you'll start looking for ways to solve more complex tasks - and Delphi will have all the answers!
Close Previous Application Instances / Ensure One Instance Running
If, for whatever the reason, you need to terminate the running instance(s) of your application when the user decides to start a new instance, you need to find a mechanism to notify all the running instances (and optionaly) close them. This article shows you one such mechanism when using Delphi.
If, for whatever the reason, you need to terminate the running instance(s) of your application when the user decides to start a new instance, you need to find a mechanism to notify all the running instances (and optionaly) close them. This article shows you one such mechanism when using Delphi.
Display a TopMost System Modal Message Box
If you really want to grab the user attention and stop him from doing anything else, you need to be able to display a system-modal topmost message box even when your application is not active. Here's how when using Delphi.
If you really want to grab the user attention and stop him from doing anything else, you need to be able to display a system-modal topmost message box even when your application is not active. Here's how when using Delphi.
Display a Password Dialog when Restoring a Delphi Application from the TaskBar
Suppose you have a data-critical type of application where you would not want a non-authored user to work with the data. What if you need to display a password dialog *before* the application is restored to make sure an authorized user is accessing it? Here's how to do it in Delphi.
Suppose you have a data-critical type of application where you would not want a non-authored user to work with the data. What if you need to display a password dialog *before* the application is restored to make sure an authorized user is accessing it? Here's how to do it in Delphi.
Display a LogIn Dialog Before the Main Form of an Application is Created
If you need to implement some kind of authorization for your Delphi application you might want to display a login / password dialog *before* the main form is created and displayed to the user. In short, the idea would be to create, display, and destroy the "login" dialog before creating the main form. Here's how.
If you need to implement some kind of authorization for your Delphi application you might want to display a login / password dialog *before* the main form is created and displayed to the user. In short, the idea would be to create, display, and destroy the "login" dialog before creating the main form. Here's how.
Delphi IDE Add-In: Simple About Delphi Programming RSS Reader
With the "Current Headlines" Delphi IDE Add-In you can get the About Delphi Programming RSS feed without even leaving the Delphi IDE. Full source code for a simple Delphi IDE menu wizard included!
With the "Current Headlines" Delphi IDE Add-In you can get the About Delphi Programming RSS feed without even leaving the Delphi IDE. Full source code for a simple Delphi IDE menu wizard included!
Listening to the Clipboard: Clipboard Delphi Spy with Custom Clipboard Formats
Extending the clipboard's flexibility and functionality from Delphi. Taking control over the Clipboard with custom formats. Coding Delphi to receive clipboard change notifications.
Extending the clipboard's flexibility and functionality from Delphi. Taking control over the Clipboard with custom formats. Coding Delphi to receive clipboard change notifications.
Intercepting Keyboard Input with Delphi - Implementing a Keyboard Hook
Intercepting keyboard input for controls that cannot receive the input focus. Working with keyboard hooks in Delphi.
Intercepting keyboard input for controls that cannot receive the input focus. Working with keyboard hooks in Delphi.
Understanding and Using Windows Callback Functions in Delphi
Simply put, a callback function is a routine in your program that Windows calls. A good example of a Windows API functions that require callback functions are enumeration functions. LEarn how to use Windows Callback in Delphi applications.
Simply put, a callback function is a routine in your program that Windows calls. A good example of a Windows API functions that require callback functions are enumeration functions. LEarn how to use Windows Callback in Delphi applications.
Creating, Parsing and Manipulating XML Documents with Delphi
Everything you need to know about Delphi and the Extensible Markup Language. Find out about creating and parsing XML documents, look for parser components and more.
Everything you need to know about Delphi and the Extensible Markup Language. Find out about creating and parsing XML documents, look for parser components and more.
Drag a Delphi Form Without the Caption Bar
No title bar! How can we drag such a window? It's easy and fun: let's make a Delphi form move by clicking (and dragging) in it's client area.
No title bar! How can we drag such a window? It's easy and fun: let's make a Delphi form move by clicking (and dragging) in it's client area.
Creating and Using DLLs from Delphi
A Dynamic Link library, or DLL, is a collection of routines (small programs) that can be called by applications and by other DLLs. Using Delphi, we can write and use our own DLLs, and we can call functions in DLLs developed with other systems / by other developers. Find out how.
A Dynamic Link library, or DLL, is a collection of routines (small programs) that can be called by applications and by other DLLs. Using Delphi, we can write and use our own DLLs, and we can call functions in DLLs developed with other systems / by other developers. Find out how.
Customizing the System Menu
What if you want to add a custom item to the system menu of an application, or delete/change the default Close caption, or even add some bitmap to it? This article shows how to handle (add, delete, change, add bitmap,...) your own system menu items and how and where to process them, by using Windows API and Delphi.
What if you want to add a custom item to the system menu of an application, or delete/change the default Close caption, or even add some bitmap to it? This article shows how to handle (add, delete, change, add bitmap,...) your own system menu items and how and where to process them, by using Windows API and Delphi.
Create a Windows Start-Up Manager
How to build a program (using Delphi) that allows a user to control which applications will run when Windows starts up. Full source code (heavily documented) included.
How to build a program (using Delphi) that allows a user to control which applications will run when Windows starts up. Full source code (heavily documented) included.
How to Create a Windows Shortcut (.LNK) File from Delphi Code
Creating a standard Windows shortcut file from Delphi.
Creating a standard Windows shortcut file from Delphi.
How to Send Information (String, Image, Record) Between Two Delphi Applications
Learn how to send the WM_CopyData message between two Delphi applications to exchange information and make two applications communicate. The accompanying source code demonstrates how to send a string, record (complex data type) and even graphics to another application.
Learn how to send the WM_CopyData message between two Delphi applications to exchange information and make two applications communicate. The accompanying source code demonstrates how to send a string, record (complex data type) and even graphics to another application.
Executing and Running Applications and Files from Delphi Code
Executing and Running Applications and Files from Delphi Code.
Executing and Running Applications and Files from Delphi Code.
How to Hook the Mouse to Catch Events Outside of your Delphi application
Learn how to track the mouse activity even when your application is not active, sits in the Tray or does not have any UI at all. By installing a system wide (or global) mouse hook you can track what the user is doing with the mouse and act accordingly.
Learn how to track the mouse activity even when your application is not active, sits in the Tray or does not have any UI at all. By installing a system wide (or global) mouse hook you can track what the user is doing with the mouse and act accordingly.
An introduction to working with Windows Registry from Delphi applications
Some basic facts on using Delphi and the Windows Registry database.
Some basic facts on using Delphi and the Windows Registry database.
DLLs Made Simpler
This article is aimed at removing the fear of writing DLLs for beginners. A lot of beginners think DLLs are really complex, when actually they are pretty simple
This article is aimed at removing the fear of writing DLLs for beginners. A lot of beginners think DLLs are really complex, when actually they are pretty simple
Retrieving volume's (disk / drive) serial number
Here is a handy piece of Delphi code to read the serial number of a (disk) drive.
Here is a handy piece of Delphi code to read the serial number of a (disk) drive.
A guide to developing Delphi programs in Windows API (without the use of the VCL)
A guide to developing Delphi programs in Windows API (without the use of the VCL). Free online programming course for intermediate/advanced Delphi developers. Focus on raw Windows API programming.
A guide to developing Delphi programs in Windows API (without the use of the VCL). Free online programming course for intermediate/advanced Delphi developers. Focus on raw Windows API programming.
Message in the Bottle
One of the keys to traditional Windows programming is handling the messages sent by Windows to applications. Handling Windows Messages the Delphi way!
One of the keys to traditional Windows programming is handling the messages sent by Windows to applications. Handling Windows Messages the Delphi way!
Tips, tricks and code samples
Using API calls to get the low level Windows functionality: working with fonts, drives, processes, etc
Using API calls to get the low level Windows functionality: working with fonts, drives, processes, etc
"The Big Brother" Delphi code toolkit
Going undercover: hiding from the task list, disabling task-switch, removing from the TaskBar, disabling shut down, ...
Going undercover: hiding from the task list, disabling task-switch, removing from the TaskBar, disabling shut down, ...
Computer restrictions with Delphi and Registry
How to enable your applications to make restrictions to what users can (and cannot) do with their computer using Delphi and the Registry.
How to enable your applications to make restrictions to what users can (and cannot) do with their computer using Delphi and the Registry.
Sending messages to non-windowed applications
Learn how to send messages (signals) to non-windowed applications by using AllocateHWND and DefWindowProc. In this article we also briefly describe what Delphi does in the background to intercept Windows messages, how can we write our own message handler for a windowed application and how to obtain a unique message identifier that we can safely use in our applications.
Learn how to send messages (signals) to non-windowed applications by using AllocateHWND and DefWindowProc. In this article we also briefly describe what Delphi does in the background to intercept Windows messages, how can we write our own message handler for a windowed application and how to obtain a unique message identifier that we can safely use in our applications.
An introduction to hook procedures
This document describes what Windows hooks are and how to use them within a Delphi application.
This document describes what Windows hooks are and how to use them within a Delphi application.
Disk in drive A:
Some useful routines when working with floppy disk and Delphi.
Some useful routines when working with floppy disk and Delphi.
Get and Set Display Device Modes
Changing the display mode settings (resolution and color depth) from Delphi code.
Changing the display mode settings (resolution and color depth) from Delphi code.
Hey Windows, Call me!
Let Windows work for you: implementing function callbacks with Delphi. Project: list all windows in Windows.
Let Windows work for you: implementing function callbacks with Delphi. Project: list all windows in Windows.
Monitoring Registry Changes
Need to get notified about changes to the attributes or contents of a specified Registry key? Them you are ready for: Part 4 to your 'Big Brother' Delphi code toolkit.
Need to get notified about changes to the attributes or contents of a specified Registry key? Them you are ready for: Part 4 to your 'Big Brother' Delphi code toolkit.
NO GUI Delphi applications
Creating a console mode application with Delphi; a text-mode program that runs without a graphical interface. Even more: see how to capture the output of a console application in a GUI Delphi program.
Creating a console mode application with Delphi; a text-mode program that runs without a graphical interface. Even more: see how to capture the output of a console application in a GUI Delphi program.
Touch Me - I'm Untouchable
Intercepting keyboard input for controls that cannot receive the input focus. Working with keyboard hooks from Delphi.
Intercepting keyboard input for controls that cannot receive the input focus. Working with keyboard hooks from Delphi.
Virtual Key Codes
Symbolic constant names, hexadecimal values, and keyboard equivalents for the virtual key codes used by Windows.
Symbolic constant names, hexadecimal values, and keyboard equivalents for the virtual key codes used by Windows.
Sticky Windows
How to dock your Delphi forms to the edges of your desktop screen.
How to dock your Delphi forms to the edges of your desktop screen.
Resource Files Made Easy
How Delphi uses standard Windows-format resource files. Bitmaps, icons, cursors and more.
How Delphi uses standard Windows-format resource files. Bitmaps, icons, cursors and more.
Registering DLL and ActiveX controls from code
How to register (and unregister) OLE controls such as dynamic-link library (DLL) or ActiveX Controls (OCX) files from a Delphi application.
How to register (and unregister) OLE controls such as dynamic-link library (DLL) or ActiveX Controls (OCX) files from a Delphi application.
Retrieving volume's (disk / drive) serial number
Here's a handy piece of Delphi code to read the serial number of a (disk) drive.
Here's a handy piece of Delphi code to read the serial number of a (disk) drive.
Delphi and Registry
Some facts on using Delphi and Windows Registry database.
Some facts on using Delphi and Windows Registry database.
Asynchronous Calling
What asynchronous calling is all about, how it can benefit your applications, and how to implement it for yourself using Microsoft Message Queue Server
What asynchronous calling is all about, how it can benefit your applications, and how to implement it for yourself using Microsoft Message Queue Server
Creating Custom Windows Event Logs
The article explains what is involved in creating custom event logs and why they will come in handy to monitor your applications.
The article explains what is involved in creating custom event logs and why they will come in handy to monitor your applications.
Locate, Display and Execute Control Panel Applets
Interested in Delphi code to mimic the Windows Control Panel folder behavior? In this article you can learn how to find CPL files, how to extract description, name and even the applet icon. Even more, learn how to execute applets from your applications.
Interested in Delphi code to mimic the Windows Control Panel folder behavior? In this article you can learn how to find CPL files, how to extract description, name and even the applet icon. Even more, learn how to execute applets from your applications.
Hardware I/O Port Programming with Delphi and NT
Delphi I/O Port Programming under NT and an I/O Port Map Manipulator driver
Delphi I/O Port Programming under NT and an I/O Port Map Manipulator driver
Hook: Capture keys in all Windows applications
How to capture keypresses in all applications that are runing in Windows.
How to capture keypresses in all applications that are runing in Windows.
NTFS Disk Quotas
With the introduction of NTFS version 5 in Windows 2000, administrators finally have the benefits of a built-in quota management system. In this article we’ll look at how you can control disk quotas from your applications.
With the introduction of NTFS version 5 in Windows 2000, administrators finally have the benefits of a built-in quota management system. In this article we’ll look at how you can control disk quotas from your applications.
Multiple app. instances
How can I guarantee that only one instance of my program executes? Final answer.
How can I guarantee that only one instance of my program executes? Final answer.
Project Jedi
Project JEDI's paramount goal is to extend Delphi's native access to the Windows API by translating C/C++ headers of popular but as yet unsupported technologies into Delphi interface units.
Project JEDI's paramount goal is to extend Delphi's native access to the Windows API by translating C/C++ headers of popular but as yet unsupported technologies into Delphi interface units.
The Win API: An Example Of Use
An example of interfacing to the Windows Application Programming Interface (API).
An example of interfacing to the Windows Application Programming Interface (API).
Managing Windows Services
The Service and Service Application wizards in Delphi make writing Windows NT/2000 services easy. This article examines the Windows API functions that let you install, remove, control, and configure services.
The Service and Service Application wizards in Delphi make writing Windows NT/2000 services easy. This article examines the Windows API functions that let you install, remove, control, and configure services.
Undocumented Windows API
The undocumented and secret Win API calls.
The undocumented and secret Win API calls.
VCL secrets and the practical use of the Win32 API
This paper introduces you to a number of under-the-hood techniques in Delphi as well as how to achieve a number of goals using the Win32 API. The Delphi RTL and VCL are rich in under-used facilities, many of them undocumented anywhere but the source.
This paper introduces you to a number of under-the-hood techniques in Delphi as well as how to achieve a number of goals using the Win32 API. The Delphi RTL and VCL are rich in under-used facilities, many of them undocumented anywhere but the source.
API: A Brief Lesson About Win Api Functions
"Windows API calls are just calls to dynamic link libraries"...
"Windows API calls are just calls to dynamic link libraries"...
Rectangles
A Closer Look at the TRect Windows Data Type.
A Closer Look at the TRect Windows Data Type.
Windows NT Privileges
how to discover and set Windows NT privileges from your applications, so you can make better use of Windows’ built-in security capabilities
how to discover and set Windows NT privileges from your applications, so you can make better use of Windows’ built-in security capabilities
