You are not logged in. You can browse in the PowerBASIC Community, but you must click Login (top right) before you can post. If this is your first visit, check out the FAQ or Sign Up.
%TVI_ROOT is a constant for a handle type and, thus, is properly defined
as a DWORD quantity, &HFFFF0000???. In most cases, it is also safe to
define it as the equivalent LONG quantity, &HFFFF0000&. The only case
where you might have a problem with this is when doing a direct comparison
of the values (say, in an IF..THEN construct).
Originally posted by Tom Hanlin: The only case where you might have a problem with this is when doing a direct comparison
of the values (say, in an IF..THEN construct).
Tom --
Your reaction talks that you didn't test Hex$(%TVI_ROOT)
Compiler SHOULD produce the same image for &HFFFF0000??? and &HFFFF0000&, but ...
Code:
#Compile Exe
#Register None
#Dim All
Function PbMain
MsgBox Hex$(&HFFFF0000???),, Hex$(&HFFFF0000&)
End Function
Additional test (what happends with TreeView_DeleteAllItems)
Code:
#Compile Exe
#Register None
#Dim All
#Include "Win32Api.Inc"
%TVI_ROOT = &HFFFF0000???
CallBack Function DlgProc
Select Case CbMsg
Case %WM_USER + 1
SetWindowText CbHndl, "Should be " + Hex$(CbWparam) + " BUT RECEIVED " + Hex$(CbLparam)
End Select
End Function
Function PbMain
Local hDlg As Long
Dialog New 0, "Palette",,, 400, 100, %WS_SYSMENU Or %WS_CAPTION To hDlg
PostMessage hDlg, %WM_USER + 1, &HFFFF0000&, %TVI_ROOT
Dialog Show Modal hDlg Call DlgProc
End Function
We process personal data about users of our site, through the use of cookies and other technologies, to deliver our services, and to analyze site activity. For additional details, refer to our Privacy Policy.
By clicking "I AGREE" below, you agree to our Privacy Policy and our personal data processing and cookie practices as described therein. You also acknowledge that this forum may be hosted outside your country and you consent to the collection, storage, and processing of your data in the country where this forum is hosted.
Comment