I thinked to create a small listbox with chechbox with all buttons of the ribbonbar
How I can make this ?
Any Idea ?
Falconi Silvio
I thinked to create a small listbox with chechbox with all buttons of the ribbonbar
How I can make this ?
Any Idea ?
Silvio,
You could use a browse or an ownerdraw listbox.
The browse will provide you more possibilities.
I try your tree checkbox sample but there is error
Antonio,
Can I have a small sample to create a Tree with checkbox from database
the database can be in this structure
NAME FIELD TYPE SIZE
Code C 6
desc C 30
BMP N 9
CHECK L 1
I want insert different bitmaps for each record
Silvio,
On each post you ask for a different thing ![]()
You have enough technical skills to try it for yourself ![]()

have try to click on each check box ?
it make me error
and to insert a bmp for each record wich is the command ?
Silvio,
> have try to click on each check box ?
Yes, here it works fine on Windows 7 Ultimate 32 bits.
> it make me error
What error is it ? Please provide an accurate feedback so we can properly help you.
You are not a novice in these forums ![]()
// Using a TreeView with checkboxes and checking their status
#include "FiveWin.ch"
function Main()
local oDlg, oTree
DEFINE DIALOG oDlg
oTree = TTreeView():New( 0, 0, oDlg,,,,,200,200,,.t.)
oTree:OnClick = { || CheckStatus( oTree, oTree:aItems ) }
ACTIVATE DIALOG oDlg CENTERED ON INIT BuildTree( oTree )
return nil
function BuildTree( oTree )
local oMenu := Array( 2 ), oSubMenu := Array( 3 )
oMenu[ 1 ]:= oTree:Add( "Principal" )
oSubMenu[ 1 ]:= oMenu[ 1 ]:Add( "Imprimir..." )
oSubMenu[ 1 ]:SetCheck( .T. )
oMenu[ 2 ]:= oTree:Add( "Proyectos" )
oSubMenu[ 2 ]:= oMenu[ 2 ]:Add( "Definir Proyectos" )
oSubmenu[ 3 ]:= oMenu[ 2 ]:Add( "Actualización datos" )
oTree:Expand()
return nil
function CheckStatus( oTree, aItems )
local n
for n = 1 to Len( aItems )
MsgInfo( oTree:GetCheck( aItems[ n ] ) )
CheckStatus( oTree, aItems[ n ]:aItems )
next
return nilMETHOD HandleEvent( nMsg, nWParam, nLParam ) CLASS TTreeView
local oItem
do case
case nMsg == WM_CHAR
if nWParam == VK_RETURN
return 1
endif
endcase
return Super:HandleEvent( nMsg, nWParam, nLParam )