The Datagrid control is group consisting of a table field with some accessories. Users can sort data by column.
You can't ungroup a datagrid. The Datagrid has a lot of built in properties and functions, you can read all here: datagrid API.
You can customize a datagrid, here is the procedure: customizing a datagrid
- Disabled: it becomes gray and not editable
- Border: an external box border
- border width
- Visible: if it's false, object is invisible
- Style: table or form. Table is a grid, form is just one column
- Row template
- row behaviour
- Allow text editing
- Alternate row colors
- auto hilite rows
- multi-row hilite
- Drag resizing
- Fixed row height
- row height
- Cache control
- Perstistent data
- Refresh data grid
- Layer mode
Here there is a large area where you can add your contents, seeing it with the wrap line on, transform it into a table, or load from a file. This property is called dgTEXT.
When the content is set like a table, content is a simple tabbed text. Every cell is separated from the other with a TAB, every line is separated from the other with a newline. For example, the following can be a 3x3 table:
11 12 13 21 22 23 31 32 33
Creating a TABBED table is easy, look the following example:
put "11" & tab & "12" & return & "21" & tab & "22" into myvar
Here you can modify many ascpects of the columns.
- Show column headers
Select a column from the list and just for that column you can edit:
- Column order
- Columns names
- Columns labels
- Drag to resize
- min and max resize allowed
- aligning: left, center or right
- sort by column
- direction: ascending or descending
- type: text, numeric, datetime, ...
- Case sensitive
- Column behaviour
This way every column can be with its own settings.
Icons & BorderEdit
- Hilite Icon: icon when the button is pressed
- Disabled Icon: icon when the button is disabled
- Visited Icon: icon when the button was pressed at least one time. You can reset a visited button setting the visited property to false
- Armed Icon
- Hover Icon: when mouse is on the object
- Three D: effect of the button
- Border: border of the button
- Hilite border: special border when pressed
- Border width
- Shadow: shadow effect of the button
- Shadow offset: distance of the shadow from the button
Colors & patternsEdit
Here you can set the color of various elements of the button. You can choose a pattern instead of a color.
Custom properties are the best replacement for variables in Livecode. You can use variables in Livecode, but usually they are just temporary; on the contrary custom properties are real containers for all your data. Easy to recover and to check.
See Geometry manager
Graphic effectsEditHere you can activate and mix many effects:
- drop shadow
- inner shadow
- outer glow
- inner glow
- color overlay
If you activate the drop shadow, you can manipulate all aspects of it (color, opacity, position, etc.) with the submenu.
The blending effect is a way to make the object transparent, you can choose between many way to render the resulting object (artihmentic, subpin, etc.). You can choose the percentage of blending your objenct with the background.
All the property of an object are inherited from a master profile, however you can add and change profile. This way all objects will have the same properties, will look the same or act the same.
Size & PositionEdit
Here you can
- specify the size of the object
- fit it to text content
- set location using the center of the object or its borders
- lock size and position
- choosing which element is above the others, specifying object layer
Here you can change:
- font type
- font size (you can enter size directly, you are not restricted to the few showed)
- font style:
- boxed 3D
You can also change all letter to uppercase, lowercase or else using tha last button.