Delphi Learn About The Handle Property in DelphiVCL.Application

FireWind

Свой
Регистрация
2 Дек 2005
Сообщения
1,957
Реакции
1,199
Credits
4,009
Learn About The Handle Property in DelphiVCL.Application
By Muhammad Azizul Hakim October 15, 2021

The Handle property or DelphiVCL.Application.Handle is used to provide access to the underlying Windows screen object for the control.

The Handle property returns the window handle for the underlying Microsoft Windows screen object. Use the Handle property to bypass the VCL API and directly access the underlying window.

Do not refer to the Handle property during component creation or streaming. The underlying window does not exist until the first time the Handle property is referenced. When this occurs, the Для просмотра ссылки Войди или Зарегистрируйся method is called automatically.

Handle is a read-only property.

Note: On Win64, the size of HANDLE types has changed to 64-bits –except for OLE_HANDLE, which is now a 32bit Long even in Win64. This means that you need to change any code that assumed OLE_HANDLE and other HANDLE types are interchangeable. Read this link for additional information: Для просмотра ссылки Войди или Зарегистрируйся

How to browse the properties and methods of DelphiVCL.Application.Handle?​

Let’s browse all the properties and methods of DelphiVCL.Application.Handle using dir() command:
Python:
import DelphiVCL
 
dir(DelphiVCL.Application.Handle)
See the responses in our Windows command prompt:
1634280372891.png
You can also read short information about the DelphiVCL.Application.Handle using the print() command:
Python:
print(DelphiVCL.Application.Handle)
print(DelphiVCL.Application.Handle.__doc__)
See the responses in our Windows command prompt:
1634280404617.png