View Issue Details

IDProjectCategoryView StatusLast Update
0006710JEDI VCL00 JVCL Componentspublic2021-04-23 17:47
ReporterCDamettoAssigned ToAHUser 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
PlatformDelphi 10.3 RioOSWindowsOS Version10
Product VersionDaily / GIT 
Target VersionFixed in VersionDaily / GIT 
Summary0006710: It is no longer possible to hide a CheckBox of a JvCheckTreeView
DescriptionI once did:
JvCheckTreeView1.CheckBox[JvCheckTreeView1.Items[0]] := False;
Now it doesn't work anymore.



Additional InformationI have attached a trial
TagsJvCheckTreeView

Activities

CDametto

2021-01-25 09:07

reporter  

CheckTreeView_trial.zip (1,216,535 bytes)

AHUser

2021-04-20 20:21

developer   ~0021963

Handling error:

You need to change CheckBoxOptions.Style to cbxJVCL. Otherwise it will use the native style and that only supports Checkboxes and can't hide Checkboxes. Unfortunately CheckBoxOptions.Style is reset to cbxNone if you change the CheckBoxes property to False. So toggling the "Checkboxes" property will switch back to the native style.

CDametto

2021-04-21 09:24

reporter   ~0021964

Ok, I couldn't find a solution, that doesn't require pressing a button...

AHUser

2021-04-22 00:51

developer   ~0021965

What do you mean by "that doesn't require pressing a button..." ? The Mantis bug tracking system?

Just putting
CheckBoxOptions.Style := cbxJVCL;
into the code uses the JVCL checkboxes implementation that supports disabling checkboxes per node.

CDametto

2021-04-22 11:38

reporter   ~0021966

Sorry, I was referring to the trial I had attached...
I tried to set:
  JvCheckTreeView1.Checkboxes := True;
  JvCheckTreeView1.CheckBoxOptions.Style: = cbsJVCL;
then I tried to hide the checkbox with each:
  JvCheckTreeView1.CheckBox[JvCheckTreeView1.Items[0]] := False;
  JvCheckTreeView1.Items[0].StateIndex := -1;
but none of them worked for me.

AHUser

2021-04-23 16:22

developer   ~0021967

Last edited: 2021-04-23 16:25

View 2 revisions

For me it works as you can see in the attach image.


UPDATE:
Now I understand. Your example with the button isn't what you want. You want to hide the checkbox for example in the FormCreate event. And that doesn't work.



Mantis6710.png (32,534 bytes)
Mantis6710.png (32,534 bytes)

AHUser

2021-04-23 17:47

developer   ~0021968

I have fixes this now. There was a bug fix from 2013 that broke the SetCheckBox code because it only worked with in the Native mode but not in the JVCL mode.

Issue History

Date Modified Username Field Change
2021-01-25 09:07 CDametto New Issue
2021-01-25 09:07 CDametto Tag Attached: JvCheckTreeView
2021-01-25 09:07 CDametto File Added: CheckTreeView_trial.zip
2021-04-20 20:21 AHUser Assigned To => AHUser
2021-04-20 20:21 AHUser Status new => feedback
2021-04-20 20:21 AHUser Note Added: 0021963
2021-04-21 09:24 CDametto Note Added: 0021964
2021-04-21 09:24 CDametto Status feedback => assigned
2021-04-22 00:51 AHUser Note Added: 0021965
2021-04-22 00:52 AHUser Status assigned => feedback
2021-04-22 11:38 CDametto Note Added: 0021966
2021-04-22 11:38 CDametto Status feedback => assigned
2021-04-23 16:22 AHUser File Added: Mantis6710.png
2021-04-23 16:22 AHUser Note Added: 0021967
2021-04-23 16:25 AHUser Note Edited: 0021967 View Revisions
2021-04-23 17:47 AHUser Status assigned => resolved
2021-04-23 17:47 AHUser Resolution open => fixed
2021-04-23 17:47 AHUser Fixed in Version => Daily / GIT
2021-04-23 17:47 AHUser Note Added: 0021968