Code:
FOR i = 1 TO 10 TREEVIEW INSERT ITEM CB.HNDL,%IDC_TV, 0, %TVI_LAST, 0, 0, "List " & FORMAT$(i) TO hTV1 IF i=4 THEN #DEBUG PRINT "-- i=4: should be checked here" TREEVIEW SET CHECK CB.HNDL, %IDC_TV, hTV1, 1 TREEVIEW SET BOLD CB.HNDL, %IDC_TV, hTV1, 1 hTV1_line4 = hTV1 END IF NEXT TREEVIEW SET CHECK CB.HNDL, %IDC_TV, hTV1_line4, 0
I also noticed that I had to remove %TVS_HASLINES to make the full row select functional for the treeview. Maybe PB help should have that mentioned too (as it is printed in MSDN for the %TVS_FULLROWSELECT: "This style cannot be used in conjunction with the %TVS_HASLINES style")
Another problem for me is that clicking at checkbox will not generate %WM_NOTIFY as clicking at other part of the line will. But these are still in study process.
cheers.. aSa
Leave a comment: