Contents
Display Legacy Contents

 Print
    Switch Button    

An Switch Button is similar to a Check Button. In fact, it's a Check Box with a customized text for the 2 statuses: on or off. Unlike Check Box, a Switch Button cannot have text besides the already mentioned. You can also link a Switch Button to the Database. A
Switch Button can interact with the user through its Events. You can use a Switch Button to display true/false options or fields.

Value - Its value is either 1 (on) or 0 (off).
Properties - General
GENERAL

Name – Name of the Control
This Name will be used to identify the Control throughout the Project. The name of the Control can only contain letters, digits or underscore (_).


"ON" Text – Text of the Switch Button when it's on
If you click on at the side of this property, you’ll be able to set the value of it in each Language of the Project.

"OFF" Text – Text of the Switch Button when it's off
If you click on at the side of this property, you’ll be able to set the value of it in each Language of the Project.


Description – Description of the Control
This Description is for your information only, Kalipso does nothing with it. If you click on at the side of this property, you’ll be able to set the value in each Language of the Project.

Plane – Plane of the Form where the Control should be created
Check the Planes chapter for more information.

Width – Width of the Control
You can set this value is runtime via the “Set Property” Action. You can retrieve this value in runtime via the “Get Property” Action. If you click on at the side of this property, you’ll be able to set the value of it in both Portrait and Landscape orientation (see the Project Properties).

Height – Height of the Control
You can set this value is runtime via the Set Property Action. You can retrieve this value in runtime via the Get Property Action. If you click on at the side of this property, you’ll be able to set the value of it in both Portrait and Landscape orientation (see the Project Properties).

From Left – X position of the Control
You can set this value is runtime via the Set Property Action. You can retrieve this value in runtime via the Get Property Action. If you click on at the side of this property, you’ll be able to set the value of it in both Portrait and Landscape orientation (see the Project Properties).

From Top – Y position of the Control
You can set this value is runtime via the Set Property Action. You can retrieve this value in runtime via the Get Property Action. If you click on at the side of this property, you’ll be able to set the value of it in both Portrait and Landscape orientation (see the Project Properties).



STYLE

Font – Font of the displayed Text

Size – Font size of the displayed Text

Properties – Font properties of the displayed Text

Font Color – Font color of the displayed Text
You can set this value is runtime via the “Set Property” Action. You can retrieve this value in runtime via the “Get Property” Action.

Backg. Color – Background color of the Control
You can set this value is runtime via the Set Property Action. You can retrieve this value in runtime via the Get Property Action.


Embed page 'style_Border' not found.

 
Properties - Links

Source Origin of the data to show in the Switch Button

- Nothing: Unlinked Switch Button
- Database Table: Connect the Switch Button with a Column of a Database Table.
- Expression: Fill the Switch Button with the result of an Expression.

  Source: Database Table

There are two ways of connecting your Input Box to a Database Table therefore presenting the value of a specific Column.

1 – You can do it by simply defining the "Table" and "Column" properties and then using the "First Record"/"Last Record"/"Next Record"/"Previous Record" and "Refresh"/"Refresh Plane"/"Refresh Control" Actions.

2 – The other way is to implicitly define a "Select" statement. To do so, you have to define the "Table", "Column", "Where the value of" and "It’s equal to" properties then use the Refresh", "Refresh Plane" or "Refresh Control" Action. This way you are telling Kalipso to perform a "Select" statement like this:

Select <Column> from <Table> where <Where the value of> = <It’s equal to>


  Source: Expression
Fill the Control with the result of – Expression whom result will be shown in the Switch Button

For the Expression to be evaluated and fill the Switch Button you’ll have to perform a "Refresh", "Refresh Plane" or "Refresh Control" Action.

  Target

Mandatory – To define if the Input Box must be filled or not when performing a “Create Record”, “Update Record” or “Create/Update Record” Action.

If this property is set, when Kalipso tries to use the value of this Switch Button for executing one of the above Actions, it checks if the value is non empty; if it’s not, Kalipso will produce an automatic error message.

Global Variable – Global Variable where to store the Switch Button value;

Local Variable – Local Variable where to store the Switch Button value;

Database Table – Table where to store the Switch Button value;

Database Column – Column where to store the Switch Button value;

The Switch Button value is retrieved and stored in the corresponding Database Table and Column when you execute a Create Record”, “Update Record” or “Create/Update Record” Action on the “Database Table”.


Shortcuts
F2 – Actions

F3 – General properties

See also
 
Updated: 10/31/2016 4:27 PM