DEFINE TREE Creates a Tree control
|
Creates a tree control.
SYNTAX
DEFINE TREE <ControlName>
[ID <nId>]
[ OF, PARENT, DIALOG> <ParentWindowName> ]
AT <nRow> ,<nCol>
[ WIDTH<nWidth> ]
[ HEIGHT<nHeight> ]
[ VALUE <nValue> ]
[ FONT <cFontName> SIZE <nFontSize> ]
[ BOLD ] [ ITALIC ] [ UNDERLINE ] [ STRIKEOUT ]
[ BACKCOLOR <anBackColor> ]
[ FONTCOLOR <anFontColor> ]
[ LINECOLOR <anLineColor> ]
[ INDENT <nIndent> ]
[ ITEMHEIGHT <nItemHeight>]
[ TOOLTIP <cToolTipText> ]
[ ON GOTFOCUS <OnGotFocusProcedure> | <bBlock> ]
[ ON CHANGE <OnChangeProcedure> | <bBlock> ]
[ ON LOSTFOCUS <OnLostFocusProcedure> | <bBlock> ]
[ ON DBLCLICK <OnDblClickProcedure> | <bBlock> ]
[ ON INIT <bInit> ]
[ BREAK ]
[ NODEIMAGES <aImgNode> [ ITEMIMAGES <aImgItem> ] [ NOROOTBUTTON ] ]
[ ITEMIDS ]
[ HELPID <nHelpId> ]
or in dialog:
REDEFINE TREE <ControlName>
ID <nId>
[ OF, PARENT, DIALOG> <ParentWindowName> ]
[ VALUE <nValue> ]
[ FONT <cFontName> SIZE <nFonSize> ]
[ BOLD ] [ ITALIC ] [ UNDERLINE ] [ STRIKEOUT ]
[ BACKCOLOR <anBackColor> ]
[ FONTCOLOR <anFontColor> ]
[ LINECOLOR <anLineColor> ]
[ INDENT <nIndent> ]
[ ITEMHEIGHT <nItemHeight>]
[ TOOLTIP <cToolTipText> ]
[ ON GOTFOCUS <OnGotFocusProcedure> | <bBlock> ]
[ ON CHANGE <OnChangeProcedure> | <bBlock> ]
[ ON LOSTFOCUS <OnLostFocusProcedure> | <bBlock> ]
[ ON DBLCLICK <OnDblClickProcedure> | <bBlock> ]
[ ON INIT <bInit> ]
[ BREAK ]
[ NODEIMAGES <aImageNode> [ ITEMIMAGES <aImageItem> ] [ NOROOTBUTTON ] ]
[ ITEMIDS ]
[ HELPID <nHelpId> ]
...
...
...
[ END NODE ]
...
...
END TREE
SPLITBOX VERSION
DEFINE TREE <ControlName>
[ OF | PARENT <ParentWindowName> ]
[ WIDTH<nWidth> ]
[ HEIGHT<nHeight> ]
[ VALUE <nValue> ]
[ FONT <cFontName> SIZE <nFontSize> ]
[ BOLD ] [ ITALIC ] [ UNDERLINE ] [ STRIKEOUT ]
[ BACKCOLOR <anBackColor> ]
[ FONTCOLOR <anFontColor> ]
[ LINECOLOR <anLineColor> ]
[ INDENT <nIndent> ]
[ ITEMHEIGHT <nItemHeight> ]
[ TOOLTIP <cToolTipText> ]
[ ON GOTFOCUS <OnGotFocusProcedure> | <bBlock> ]
[ ON CHANGE <OnChangeProcedure> | <bBlock> ]
[ ON LOSTFOCUS <OnLostFocusProcedure> | <bBlock> ]
[ ON DBLCLICK <OnDblClickProcedure> | <bBlock> ]
[ ON INIT <bInit> ]
[ NODEIMAGES <aImageNode> [ ITEMIMAGES <aImageItem> ] [ NOROOTBUTTON ] ]
[ ITEMIDS ]
[ HELPID <nHelpId> ]
[ BREAK ]
nRow, nCol
|
Position in the area of ??the window in pixels.
|
nWidth, nHeight
|
The desired size of the Tree Control in pixels.
|
nId
|
The ID identifier this Control in Dialog Window
|
ControlName
|
A reference to the Tree Control
|
ParentWindowName
|
A reference to the Parent Window.
|
nHelpID
|
The help topic identifier for this Control
|
nValue
|
|
cFontName
|
Specifies the Font Name
|
nFontSize
|
Specifies the Font Size
|
anBackColor
|
Specifies the Background Color
|
anFontColor
|
Specifies the Font Color
|
anLineColor
|
Specifies the Line Color
|
nIndent
|
Specifies the Indentation
|
nItemHeight
|
Specifies the Height of the Items
|
cToolTipText
|
Specifies the Text for the ToolTip
|
OnGotFocusProcedure
|
An action to be performed when control Got Focused
|
OnChangeProcedure
|
An action to be performed when control value Changes
|
OnLostFocusProcedure
|
An action to be performed when control Got Focused
|
OnDblClickProcedure
|
An action to be performed when control is Double Clicked
|
aImageNode
|
Specifies the Image to be displayed on Tree Nodes
|
aImageItem
|
Specifies the Image to be displayed on Item
|
cNodeCaption
|
Specifies the Tree Node caption
|
aImage
|
?
|
nItemID
|
?
|
cTreeItemCaption
|
?
|
|
|
BREAK
|
?
|
NOROOTBUTTON
|
?
|
ITEMIDS
|
?
|
BREAK
|
?
|
PROPERTIES:
Set / Gets Tree value.
| |
Set / Gets enabled state of a Tree control
| |
Set / Gets visible a Tree control.
| |
Set / Gets item text in a Tree
| |
Get item count in a Tree
| |
Set / Gets row position of a Tree control.
| |
Set / Gets column position of a Tree control.
| |
Set / Gets width of a Tree control.
| |
Set / Gets height of a Tree control.
| |
Set / Gets Tree control's font name.
| |
Set / Gets Tree control's font size.
| |
Set / Gets Tree control's font bold property
| |
Set / Gets Tree control's font italic property
| |
Set / Gets Tree control's font underline property
| |
Set / Gets Tree control's font strikeout property
| |
Set / Gets the foreground color for text within the Tree
| |
Set / Gets the background color for text within the Tree
| |
Set / Gets Tree control's Tooltip text.
| |
Set / Gets user property 'Cargo' for Tree control
| |
Retrieves the name of a Tree control.
| |
Set the name as character identifier of the parent window.
| |
Set the numeric help topic identifier of the control.
| |
· LineColor
|
Sets the line color for the ident
|
· Indent (D)
|
Sets a value of ident of a Tree control
|
· ItemHeight (D)
|
Sets item height of a Tree control
|
· NodeImages (D)
|
Sets the image displayed for the node
|
· ItemImages (D)
|
Sets the image for the Tree Item
|
Control passes to the statement that follows the terminated statement.
|
EVENTS
Action to be performed when getting the focus
| |
Action to be performed when generic changing of the control
| |
Action to be performed when losing the focus.
| |
Action to be performed when Double Left clicking.
|
METHODS:
Shows a Tree control
| |
Hides a Tree control
| |
Redraw a Control
| |
Add a new item to a Tree control
| |
Deletes an item from a Tree control
| |
Deletes all items from a Tree control
| |
Expand control Tree.
| |
Collapse control Tree
| |
Gives the focus to a Tree control
| |
Releases a Tree control from memory
| |
Update enables for Tree control
| |
Update disables for Tree control
| |
Save a
Tree control as BitMap file.
|
When ITEMIDS clause is specified, you can assign a numeric ID (ID clause) to tree items and nodes. That way, all tree properties and methods will work using these id's instead item position.
EXAMPLE: