[Gambas-user] DataCheckBox properties do not exist or event not raised

Marty mmcg29440 at ...3163...
Sat Nov 30 16:02:07 CET 2013


Hello All,

I'm experiencing weird problem with the DatCheckBox control. First let 
me say I'm running Gambas 3.5.1 on Ubuntu 12.04 LTS. The project was 
started in Gambas 3.4.2 and developed further in each successive release 
of Gambas. Each DataCheckBox is in the same datasource attached to a 
MySQL table. All the qt4 components are loaded.

The problems are:

1) The first click causes the black check to disappear and the 
background turns grey. The second click  causes a grey check to appear 
and the background changes to white. The third click causes a black 
check and a white background. Is this normal?

2) The click event is not raised when the user clicks on the control.

3) the tristate property does not exist.

4) This code works in the debug mode if a breakpoint is set and I step 
through the code. If no breakpoint is set the text box value goes 
between true and false and cannot be set to true. If I do not set the 
value manually the value remains unset.

      Private Sub DataCheckBox3_MouseDown()
         If DataCheckBox3.Value = True Then
             DataCheckBox.Value = False
         Else
             DataCheckBox3.Value = False
         End If
      End

The idea is to check the state of the control, after user input, and 
call a sub to modify another table.
So far I have not been able to get this to work because of the problems 
with the checkbox. The sub is OK, I can run it from a button without 
problem.

So what is going on?

Marty




More information about the User mailing list