Code: Select all
#include "Fivewin.ch"
#define LBS_EXTENDEDSEL 2048
FUNCTION MAIN()
LOCAL oDlg
LOCAL oLbx
LOCAL cVar := ""
DEFINE DIALOG oDlg
@ 1, 1 LISTBOX oLbx VAR cVar ITEMS { "Bert", "Carl", "William" }
oLbx:nStyle += LBS_EXTENDEDSEL
@ 3, 1 BUTTON "&Test" ACTION MSGINFO( oLbx:IsMultipleSel() )
ACTIVATE DIALOG oDlg;
CENTER
RETURN NIL
Code: Select all
METHOD IsMultipleSel() INLINE lAnd( GetWindowLong( ::hWnd, GWL_STYLE ),;
nOr( LBS_MULTIPLESEL, LBS_EXTENDEDSEL ) )