Mombu the Programming Forum sponsored links

Go Back   Mombu the Programming Forum > Programming > Handle zero? Hwnd := 0
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 8th September 09:21
rob kennedy
External User
 
Posts: 1
Default Handle zero? Hwnd := 0



Any window. You can also obtain handles to other things, such as
processes, bitmaps, fonts, files, and memory, but those aren't useful if
you're looking for a window handle, so pay close attention to whether a
parameter's type is do***ented as HWnd, HProcess, HBitmap, HFont,
THandle, HGlobal, HLocal, or something else. All of them are really just
integers, so the compiler won't catch you if you pass a window handle
where a thread handle is expected, or vice versa.

No. TLabel is not a windowed control. It's a descendant of
TGraphicControl, which has no handle, as compared to TWinControl.

TGraphicControl and its descendants don't exist, as far as the OS is
concerned. When a TLabel paints itself, the OS merely sees the label's
parent being painting. Delphi manages all the graphic controls itself.
This occurs in TWinControl.PaintControls, which calls Perform on all a
control's children to send them all wm_Paint messages. Only TWinControl
descendants can receive wm_Paint messages (and any other messages) from
the OS, but with Perform, those messages can also go to non-windowed
controls.

--
Rob
  Reply With Quote


  sponsored links


2 8th September 09:21
hans-peter diettrich
External User
 
Posts: 1
Default Handle zero? Hwnd := 0



AdamMaynard24 schrieb:


A handle is something like the address of an object, where the object
usually resides in system address space, inaccessible to applications.


DoDi
  Reply With Quote
Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666