I am using this:
hFont = FF_Control_GetFont(HWND_CUSTOMPROPERTIES_LABEL2)
The label is valid and has a font, however, hFont receives a null value (0), ideas?
I found the problem in the generated source code...
'------------------------------------------------------------------
FUNCTION FF_Control_GetFont (BYVAL hWndControl AS DWORD) AS LONG
' Do a check to ensure that this is actually a window handle
IF IsWindow(hWndControl) THEN
' Get the current font
SendMessage hWndControl, %WM_GETFONT, 0, 0
END IF
END FUNCTION
Should Be...
'------------------------------------------------------------------
FUNCTION FF_Control_GetFont (BYVAL hWndControl AS DWORD) AS LONG
' Do a check to ensure that this is actually a window handle
IF IsWindow(hWndControl) THEN
' Get the current font
FUNCTION = SendMessage(hWndControl, %WM_GETFONT, 0, 0)
END IF
END FUNCTION
Hi Elias,
Right you are! I can't believe I never noticed that error over the last couple of years. I guess that I don't use the GetFont function. :)