[Gambas-user] DataControls with Visible = False

Matti math.eber at ...221...
Tue Jan 11 19:27:09 CET 2011


"Need" is too much. In some situations it could be comfortable to have hidden
DataControls that work:

1. A database field with long text can't be displayed in a DataControl, because
it's not multiline. So I have to display it in a TextLabel.
2. I want to display a field as a heading, or in the window title.
3. I want to have the text of a field on a button or a label.
Generally, if I want to retrieve fields from a database, but want another look
and/or function than DataControl = TextBox.

In these cases it would be handy to have hidden DataControls that retrieve the
data, and in the code just hand them over to the other controls.
Do you understand now?

Of course, these things can be done with a SQL query and result set. It was just
a question of laziness.

By the way: why have the children of DataSource the properties "enabled" and
"visible" then? If visible=false then enabled=false, and visible=true and
enabled=false doesn't make sense, does it?

Regards
Matti


Am 01.01.2011 17:32, schrieb Benoît Minisini:
> 
> Yes, hidden children are not taken into account by the DataSource. Why do you 
> need the contrary?
> 




More information about the User mailing list