TreeGrid XML
Mouse and key schema
TreeGrid v5.9
TreeGrid mouse and key controlling is fully customizable by settings in <Actions> tag.
<Actions>
Settings of key and mouse behaviors.
You can define all mouse and key events and actions for them - what will happen when user presses some key or clicks by mouse ...
You can define complete key and mouse control schema.
Default TreeGrid key and mouse schema is defined in Defaults.xml file.
Actions are defined globally for whole grid. To set behavior specific to given cell use appropriate cell attributes related to needed action or cell Event... attribute or specific API event handlers or API OnEvent... handler.
Remember, not all actions are suitable for every event and not all, especially key, events can be handled by JavaScript in all browsers!
Actions tag contains attributes named according event name and its value contains predefined action(s).
For example <Actions .... CtrlClickCell=’SelectRow’ ... />
Every event can have defined more actions. In fact, as action can be set any JavaScript expression that returns false to continue by default event behavior or true to stop event propagation and default action.
Basically you can separate two actions by these operators:
A + B Both actions are always executed. The return value is true if at least one action succeeded.
A && B or A AND B The second action is executed only if the first action succeeds. The return value is true if both actions succeeded.
Attention, when you use only “&” instead of “&&”, both action are always called!
A || B or A OR B The second action is executed only if the first action fails. The return value is true if at least one action succeeded.
Attention, when you use only “|” instead of “||”, both action are always called!
A ? B : C Action B is executed only when Action A succeeded, Action C is executed only when Action A failed. The colon must not be missing.
A , B Both actions are always executed. The return value is the result of the second action (the first action result is ignored).
Priority of operators is the same as in JavaScript (from highest to lowest): + && || ?: , The AND is replaced by &&, the OR is replaced by ||, the empty space by +
You can always use parenthesis to change the priority of operators.
Actions are executed in order they are listed. When action fails returns false, when succeeds returns true.
For example <Actions ... DragCell = “DragRow OR SelectRowRange” ... /> - when a user catches row by mouse the row will start being dragged if dragging is permitted for the grid and column, otherwise it starts selecting range.
Or example <Actions ... ClickCell = “StartEdit || Focus && ShowDetail” .../> - starts editing on click and if editing is not possible focuses the cell and shows it in detail grid
For every action event is run also its API event handler, if defined.
The event is named OnEventName, where the Name is event name like Click or CtrlDel, for example OnEventCtrlClick.
See API OnEvent....
You can call as action any global JavaScript function. In this case you need to use standard parenthesis ( ) after function name. In fact, you can use in action expression any JavaScript expression (but not command like assignment), but you should avoid too complicated expressions and rather call custom functions.
For example:
<Actions ClickCell=”MyFunc() OR alert(‘problem!’)”/>
and in <script>
function MyFunc(){ alert(“grid clicked”); return true; }
In action code (but not in your custom function) you can use keyword this to access the actual grid.
For example:
<Actions ClickCell=”MyFunc(this,this.ARow,this.ACol)”/>
and in <script>
function MyFunc(grid,row,col){ alert(“clicked ”+ row.id + “,”+col); return true; }
Changing action dynamically by JavaScript API
The action can be changed from JavaScript by API method ChangeAction (name, action).
For example grid.ChangeAction ("ClickCell","alert('Cell clicked')");
Calling actions from JavaScript
Every action can be also called from JavaScript by grid[“Action”+name], for example grid.ActionSave( );
To use ...F (focused) version of action, you need to call it with the first parameter as 1, for example grid.ActionSelectRow(1); => There is no method named ActionSelectRowF.
Some actions are related to focused row or cell. The focused cell can be changed by Focus method.
Some actions are related to actual row or cell. This cannot be changed, it is always cell under mouse cursor.
Calling actions from JavaScript is intended just to extend the global mouse or key schema. To provide specific actions for individual cells, use standard API methods like SelectRow or AddRow.
Actions are done usually for focused or actual cell or row. It is not the same.
Actual cell or row is under mouse cursor and focused cell or row is with TreeGrid cursor (blue by default).
Also focused row or cell is not the same as selected row or cell. There can be more selected cells and rows and is possible to delete, move or copy them, whereas focused cell is only one and it is a grid cursor.
When action says that works with actual or focused row / column / cell, it exists in two versions, one without postfix works with actual and the second with postfix F works with focused.
For example DeleteRow ...F has DeleteRow for actual row and DeleteRowF for focused row.
Every event target can have set its parent. The parent’s action is executed when this action fails.
When the focused cell (for key events) or actual cell (for mouse events) has set its Event attribute for the actual event, this action is called first.
Event name is set up from three parts: Prefix + Name + Target.
For example CtrlClickCell – Ctrl is the prefix, Click is the name, Cell is the target. For example AltEnterEdit – Alt is the prefix, Enter is the name, Edit is the target.
Prefix is state of control keys Shift, Ctrl, Alt. It can be combined of more of them or also can be empty. When combined, the keys must be in this order: Shift, Ctrl, Alt.
The prefixes are the same for mouse and key events.
For example ClickCell, CtrlClickCell, AltClickCell, ShiftClickCell, ShiftCtrlClickCell, CtrlAltClickCell, ShiftAltClickCell, ShiftCtrlAltClickCell.
Base names of events done by mouse
Click single click of left button, when its action returns true, it suppresses DblClick event.
Down left mouse button pushed down, when its action returns true, it suppresses Click event.
DblClick double click of left button
RightClick single click of right button
Drag moving mouse with left button held. The action is resolved and starts being executed when the mouse button is pushed down and mouse moves for 5px, see DragSize attribute.
A place in grid where is the mouse pointer in time of event.
Mouse events bubble. It means that if the action fails, it continues with action of parent action.
Every target can have set its parent target that will be executed when the action fails. The parent is set by TargetParent=’Target’, for example CellParent=’Grid’.
For example when a user clicks to right side button, it calls ClickButton action, if it fails, calls ClickCell, if it fails calls ClickGrid. If any action succeeds, no next action is called and bubbling stops.
Target name Parent target Description
Cell Grid Any cell except header and panel cells
Edited Actually edited cell (input or textarea). Remember, it does not have any parent event, so in this case is not called any other action.
Bool Cell Cell type Bool
Radio Cell Cell type Radio
Link Cell Link in cell type Link or Img
Button Cell Any right side button in cell
ButtonCalendar Button Right side button type “Date”
ButtonDefaults Button Right side button type “Defaults”
ButtonUser Button Right side button type “Button”, “Img”, “Html”
Expand Cell Expand / collapse icon in tree
DropCols Cell Column names in space row, usually used as custom area in Group row (To group by, drag column here ...).
Gantt Cell Gantt chart
Header Grid Any header cell (except panel) in single line header and any header cell in main row (except panel) in multiline header
HeaderMulti Header Cell in multiline header other than in main row
HeaderLeft Header Header cell left edge, size is set by EdgeSize
HeaderRight Header Header cell right edge, size is set by EdgeSize
SortDown Header Sort icon on header - top part when SortIcons is set to 2 or whole header cell top part when SortIcons is set to 3
SortUp Header Sort icon on header - bottom part when SortIcons is set to 2 or whole header cell bottom part when SortIcons is set to 3
Sort Header Sort icon header when SortIcons is set to 0 or whole header cell when SortIcons is set to 1
Panel Grid Any panel button except header
Delete Panel Panel delete button
Select Panel Panel select button
Move Panel Panel move button
Copy Panel Panel copy button
Grouped Panel Panel group on/off button in group row
Filtered Panel Panel filter on/off button in filter row
Searched Panel Panel search on/off button in search row
HeaderPanel Grid Panel in header
HeaderDelete HeaderPanel Panel delete button on header
HeaderSelect HeaderPanel Panel select button on header
HeaderCopy HeaderPanel Panel copy button on header
PagerPage Grid Pager page
PagerHeader Grid Pager caption
PagerHeaderLeft PagerHeader Pager caption left edge, size is set by EdgeSize
PagerHeaderRight PagerHeader Pager caption right edge, size is set by EdgeSize
ButtonSave Grid Toolbar button Save changes
ButtonReload Grid Toolbar button Reload grid
ButtonRepaint Grid Toolbar button Refresh pages
ButtonCalc Grid Toolbar button Calculations on / off
ButtonSort Grid Toolbar button Sorting on / off
ButtonPrint Grid Toolbar button Print
ButtonExport Grid Toolbar button Export
ButtonExpandAll Grid Toolbar button Expand all rows
ButtonCollapseAll Grid Toolbar button Collapse all rows
ButtonAdd Grid Toolbar button Add new row
ButtonAddChild Grid Toolbar button Add new row into children
ButtonCfg Grid Toolbar button Show configuration menu
ButtonColumns Grid Toolbar button Show columns visibility menu
ButtonHelp Grid Toolbar button Show help
Resize Grid Bottom right edge of grid, to resize grid
Empty Grid Any space without cells inside the grid
Grid Any point inside grid
Outside Any point outside the grid
Key names for all possible keys on keyboard.
Key names are defined by KeyNames... attributes for key scan codes. The KeyNames should not be changed, if there is not real reason to do it.
A - Z D0 - D9 (keys 0 to 9) Space Tab Backspace Enter Esc
Maxthon browser has disabled Esc key for JavaScript
F1 – F12 Ins Del Home End PageUp PageDown Up Down Left Right Pause
In IE have function keys F1 – F12 predefined action that cannot be suppressed (for example F5 always reloads page)
Some function keys F1 – F12 are reserved for system use and cannot be handled by browser on some systems
Safari and Konqueror have disabled Ins key for JavaScript
Tilde ‘~’ Minus ‘-‘ Equal ‘=’ LeftBracket ‘[‘ RightBracket ‘]’ Backslash ‘\’ Semicolon ‘;’ Apostrophe ‘’’ Comma ‘,’ Point ‘.’ Slash ‘/’
Firefox returns for Minus the code for NumMinus and for Equal unknown code 61
Opera has completely different codes for these keys and often conflicts with control keys, for example Apostrophe returns code for Right arrow.
Num0 – Num9 NumDivide NumStar NumMinus NumPlus NumPoint
Num0 – Num9 keys are identified only when NumLock is ON, otherwise the return code as control key.
The numeric Enter is always the same as Enter, so there is no NumEnter.
Firefox returns NumMinus also for Minus key
Konqueror has problems with identification of NumDivide, NumStar, NumMinus, NumPlus, NumPoint
CapsLock NumLock ScrollLock
ScrollLock on some systems does not work
By default has key event no target that is used for standard controlling when EditMode is off – no cell is being edited.
The default empty target can be referenced as parent named Default, for example EditParent=”Default”
Edit Edit mode is on, some cell is being edited. Remember this target has set no parent by default, so no keys defined in default target are used here.
EditMultiline Multiline cell (Lines type) is being edited. This event has by default set its parent to Edit.
Special events are executed for some actions in grid. They have not prefix or target.
Focus Executed when cursor is moved to another cell. It is raised by Focus action and all Navigation actions.
It can be used for example to clear selection or show detail grid.
BeforeClick Executed after any click to grid. It is executed before any click events. Its return value is ignored.
It can be used for example to clear selection.
AfterClick Executed after any click to grid. It is executed after all click events independently on their return value. Its return value is ignored.
It can be used for example to show detail grid.
BeforeDblClick Executed after double click to grid, but before any double click event. Its return value is ignored.
AfterDblClick Executed after double click to grid and after all double click events. Its return value is ignored.
BeforeRightClick Executed after right click to grid, but before any right click event. Its return value is ignored.
AfterRightClick Executed after right click to grid and after all right click events. Its return value is ignored.
“” Nothing, the event is ignored (but API OnEvent... handler is still called when is defined)
Activate Activates grid, grid will handle key events
Deactivate Deactivates grid, grid will not handle key events
Focus Focuses actual cell => moves cursor to cell under mouse cursor. It fails if cell cannot be focused.
ChangeFocus Focuses actual cell => moves cursor to cell under mouse cursor. It fails if cell is already focused or cannot be focused.
FocusRow Focuses cell in actual row and focused column. If the cell cannot be focused, focuses only row. It fails if the row cannot be focused.
StartEdit Starts editing focused cell. It fails if cell cannot be edited or there is no focused cell or some cell is already being edited.
Blur Defocuses grid, hides cursor
See also mouse dragging actions for selecting by mouse drag listed below
SelectRow ...F Selects actual or focused row, does not clear previous selection. Fails if row is already selected.
DeselectRow ...F Deselects actual or focused row, does not clear previous selection. To invert selection action use “SelectRow OR DeselectRow”
SelectCell ...F Selects actual or focused cell, does not clear previous selection. Fails if cell is already selected.
DeselectCell ...F Deselects actual or focused cell, does not clear previous selection. To invert selection action use “SelectCell OR DeselectCell”
SelectCol ...F Selects whole actual or focused column
DeselectCol ...F Deselects whole actual or focused column. To invert selection action use “SelectCol OR DeselectCol”
SelectRowRange Selects all rows between focused row and actual row, does not clear previous selection
DeselectRowRange Deselects all rows between focused row and actual row
InvertRowRangeFirst Selects or unselects all rows between focused row and actual row. If the focused row is selected, unselects all, otherwise selects all
SelectCellRange Selects all cells between focused cell and actual cell, does not clear previous selection
DeselectCellRange Deselects all cells between focused cell and actual cell
InvertCellRangeFirst Selects or unselects all cells between focused cell and actual cell. If the focused cell is selected, unselects all, otherwise selects all
SelectAll Selects all visible rows, fails if all rows are already selected. This action can be asynchronous!
DeselectAll Deselects all visible rows, fails if no row is selected. To always deselect all rows you should use ClearSelection instead!
This action can be asynchronous, so you should not call any other select actions after this in the same event!
InvertAll Inverts whole selection, unselects all visible selected rows and selects all unselected rows. It is not the same as “SelectAll OR DeselectAll”.
ClearSelection Clears whole selection, including hidden rows. It is always synchronous.
These actions can be used only for mouse Drag... events.
DragRow Starts dragging actual row to new position, possible only for Drag event. Dropped row will be moved.
DragSelected Starts dragging selected rows to new position, possible only for Drag event. Fails if actual row is not selected. Dropped row will be moved.
DragCopy Like Drag, but copies row, without its children
DragSelectedCopy Like DragSelected, but copies row, without its children
DragCopyChildren Like Drag, but copies row, with its children
DragSelectedCopyChildren Like DragSelected, but copies row, with its children
SelectCells Starts selecting cells by mouse dragging. Fails if Selecting or SelectingCells is 0.
DeselectCells Starts deselecting cells by mouse dragging. Fails if Selecting or SelectingCells is 0.
SelectRows Starts selecting rows by mouse dragging. Fails if Selecting is 0.
DeselectRows Starts deselecting rows by mouse dragging. Fails if Selecting is 0.
InvertCellsFirst Starts selecting or deselecting cells by mouse dragging. If the actual cell is selected, starts deselecting, otherwise starts selecting.
Fails if Selecting or SelectingCells is 0.
InvertRowsFirst Starts selecting or deselecting rows by mouse dragging. If the actual row is selected, starts deselecting, otherwise starts selecting.
Fails if Selecting is 0.
SelectOddRows Starts selecting individual rows – every row under mouse cursor is selected
DeselectOddRows Starts deselecting individual rows – every row under mouse cursor is deselected
InvertOddRows Starts inverting selection of individual rows - every row under mouse cursor changes its selection state
ColResize Starts resizing column
ColMove Starts moving column
DropColMove Starts moving column in DropCols (usually in Group row)
GridResize Starts resizing main tag
FillCells Starts filling cell values by the actual cell value. It fills to all cells the focused cell value. Use OnAutoFill and OnAutoFillValue events to modify filling behavior.
FillCol Starts filling cell values by the actual cell value. It fills only vertically.
FillRow Starts filling cell values by the actual cell value. It fills only horizontally.
DeleteRow ...F Deletes actual or focused row
DeleteSelected Deletes all selected rows. This action can be asynchronous!
UndeleteRow ...F Undeletes actual or focused row, to invert deletion use “DeleteRow OR UndeleteRow”
UndeleteSelected Undeletes all selected rows, to invert deletion use “UndeleteSelected OR DeleteSelected” - remember, here it depends on the order!
This action can be asynchronous!
RemoveRow ...F Physically removes the row. The row will no longer exist in grid and cannot be updated to server!
RemoveSelected ...F Physically removes all selected rows. The rows will no longer exist in grid and cannot be updated to server! This action can be asynchronous!
AddRow ...F Adds new row above actual or focused row.
AddRowBelow ...F Adds new row below actual or focused row.
AddRowEnd Adds new row to the end of page. When set <Cfg AddRowEnd=’1’/> it adds new row to the end of grid.
AddChild ...F Adds new row into actual or focused row children to the beginning
AddChildEnd ...F Adds new row into actual or focused row children to the end
MoveSelected Moves selected rows above actual or focused row
MoveSelectedChild Moves selected rows into actual or focused row children to the beginning
MoveSelectedChildEnd Moves selected rows into actual or focused row children to the end
CopyRow ...F Copies actual or focused row, the new row is placed above the row
CopyTree ...F Copies actual or focused row with all children, the new row is placed above the row
CopyEmpty ...F Copies actual or focused row with all children, but without their values, the new row is placed above the row
CopySelected ...F Copies selected rows before the actual or focused row. It copies only rows that can be copied in the location.
It fails if no selected row can be copied to the location.
CopySelectedChild ...F Like CopySelected, but copies as the first children of actual or focused row.
CopySelectedChildEnd ...F Like CopySelected, but copies as the last children of actual or focused row.
CopySelectedTree ...F Copies selected rows with children before actual or focused row.
CopySelectedTreeChild ...F Like CopySelectedChildren, but copies as the first children of actual or focused row.
CopySelectedTreeChildEnd ...F Like CopySelectedChildren, but copies as the last children of actual or focused row.
CopySelectedEmpty ...F Copies selected rows with children, but without values, before actual or focused row.
CopySelectedEmptyChild ...F Like CopySelectedEmpty, but copies as the first children of actual or focused row.
CopySelectedEmptyChildEnd ...F Like CopySelectedEmpty, but copies as the last children of actual or focused row.
CopySelectedEnd Copies selected rows to the end of the actual page
CopySelectedTreeEnd Copies selected rows with children to the end of the actual page
CopySelectedEmptyEnd Copies selected rows with children, but without values, to the end of the actual page
CopyMenu ...F Shows menu for copying or adding before actual or focused row or to children. Displaying individual menu items depends on <Panel Copy> attribute and row state.
You can also remove individual menu items by deleting texts for the menu items from Text.xml.
CopyMenuEnd ...F Shows menu for copying or adding before actual or focused row or to children or to the end of page.
CopyRowMenu ...F Shows menu for copying or adding before actual or focused row
CopyChildMenu ...F Shows menu for copying or adding to actual or focused row children to the beginning
CopyRowMenuEnd ...F Shows menu for copying or adding before actual or focused row or the end of page
CopyChildMenuEnd ...F Shows menu for copying or adding to actual or focused row children to the beginning or to the end
GoDown Goes down to the first focusable cell
GoUp Goes up to the first focusable cell
GoLeft Goes left to the first focusable cell
GoRight Goes right to the first focusable cell
TabLeft Goes left to the first focusable cell, if there is none, continues up, from right
TabRight Goes right to the first focusable cell, if there is none, continues down, from left
PageDown Goes down for count of displayed pages or when displayed one page at a time, goes to previous page. It does not change focused column.
PageUp Goes up for count of displayed pages or when displayed one page at a time, goes to next page. It does not change focused column.
GoFirst Goes to the first variable row. It does not change focused column.
GoLast Goes to the last variable row. It does not change focused column.
TabLeftEdit Goes left to the first editable cell, if there is none, continues up, from right
TabRightEdit Goes right to the first editable cell, if there is none, continues down, from left
GoLeftEdit Goes left to the first editable cell
GoRightEdit Goes right to the first editable cell
GoDownEdit Goes down to the first editable cell
GoUpEdit Goes up to the first editable cell
Expand ...F Expands actual or focused row, fails if row is already expanded or cannot be expanded or does not have children.
Collapse ...F Collapses actual or focused row, fails if row is not expanded or cannot be expanded or does not have children.
Use “Expand OR Collapse” to invert expand state
ExpandAll Expands all rows. This action can be asynchronous!
ExpandAllLoaded Expands all loaded rows (for server paging). This action can be asynchronous!
CollapseAll Collapses all rows. This action can be asynchronous!
Indent ...F Increases level of actual or focused row. Moves the row as the last child of previous row.
Outdent ...F Decreases level of actual or focused row. Moves the row below its parent row.
SortAsc ...F Sorts according to actual or focused column ascending – adds the column as the first to sorting.
Returns false if the column is already the first column and is sorted ascending otherwise sorts it ascending
SortDesc ...F Sorts according to actual or focused column descending – adds the column as the first to sorting.
Returns false if the column is already the first column and is sorted descending otherwise sorts it descending
SortAscAdd ...F Adds the actual or focused column to sorting to the end and sorts it ascending
If the column is already sorted, returns false if it is sorted ascending otherwise sorts it ascending, but does not change its position in sorting.
If there are already three columns sorted, it returns false.
When between clicks are more than two seconds or a user clicks also outside header, it clears sorting and starts from first column again.
SortDescAdd ...F Adds the actual or focused column to sorting to the end and sorts it descending, see the SortAscAdd.
NoSort ...F Removes the actual or focused column from sorting and re-sorts grid
DefaultSort Restores the sorting settings set in input XML data
SortOn Enables sorting in grid and re-sorts grid. It fails if sorting is already enabled.
SortOff Disables sorting in grid. It fails if sorting is already disabled.
GroupBy ...F Groups by actual or focused column as the first column, fails if grid is already grouped by this column
GroupByLast ...F Groups by actual or focused column as the last column, fails if grid is already grouped by this column
UnGroupBy ...F Removes the actual or focused column, fails if grid is not grouped by this column
GroupOn Enables grouping in grid and re-groups it according to actual settings. It fails if groupings already enabled.
GroupOff Disables grouping in grid and un-groups it. It does not clear actual grouping settings. It fails if groupings already disabled.
FilterOn Enables filtering in grid and re-filters it according to actual settings. It fails if filtering already enabled.
FilterOff Disables filtering in grid and un-filters it. It does not clear actual filter settings. It fails if filtering already disabled.
SearchOn Enables searching in grid and re-searches it according to actual settings. It fails if searching already enabled.
SearchOff Disables searching in grid and clear search. It does not clear actual search settings. It fails if searching already disabled.
CalcOn Enables calculations in grid and recalculates it. It fails if calculations are already enabled.
CalcOff Disables calculations in grid. It fails if calculations are already disabled.
ResizeColLeft Narrows focused column
ResizeColRight Extends focused column width
MoveColLeft Moves focused column left for one place
MoveColRight Moves focused column right for one place
HideCol ...F Hides actual or focused column
ShowColLeft ...F Shows hidden column left side from actual or focused cell
ShowColRight ...F Shows hidden column right side from actual or focused cell
CCopy... actions can be set only for CtrlC or CtrlX events, Paste... actions can be set only for CtrlV event.
Actions in these events must return 0 to permit the default function, use zero after comma like “CCopyRow,0”
CCopyRow Copies to clipboard focused row, values tab separated
CCopyCol Copies to clipboard focused column, values CRLF separated
CCopyColLevel Copies to clipboard focused column, only rows in the same parent as the focused row, values CRLF separated
CCopyCell Copies to clipboard focused cell value
CCopySelected Copies to clipboard all selected rows, cell values are tab separated, rows are CRLF separated.
ExcludeRow Copies to clipboard focused row and deletes it
ExcludeSelected Copies to clipboard all selected rows and deletes them
PasteToRow Pastes data from clipboard to focused row only, if the pasted range contains more rows, an alert is displayed.
PasteToRowFill Pastes data from clipboard to focused row and to the next rows (if in tree, in the same parent only).
PasteToRowAdd Pastes data from clipboard to focused and next rows are added after the focused row. Tree structure of pasted data is not preserved.
PasteToNewRow Inserts new rows in front of the focused row and pastes data from clipboard here. Tree structure of pasted data is not preserved.
PasteToSelected Pastes data from clipboard to selected rows, if the pasted range has different size, an alert is displayed
PasteToCol Pastes data from clipboard to focused column only, if the pasted range contains more columns, an alert is displayed.
PasteToColLevel Pastes data from clipboard to focused column only, to rows only in the same parent in tree, if the pasted range contains more columns, an alert is displayed.
PasteToColFill Pastes data from clipboard to focused column and to the next columns.
PasteToColFillLevel Pastes data from clipboard to focused column and to the next columns, to rows only in the same parent in tree
PasteToRowFirst Like PasteToRow, but pastes data always from the first left column
PasteToRowFillFirst Like PasteToRowFill, but pastes data always from the first left column
PasteToRowAddFirst Like PasteToRowAdd, but pastes data always from the first left column
PasteToNewRowFirst Like PasteToNew, but pastes data always from the first left column
PasteToSelectedFirst Like PasteToSelected, but pastes data always from the first left column
PasteToColFirst Pastes data from clipboard to focused column only, starts always in the first row, if the pasted range contains more columns, an alert is displayed.
PasteToColLevelFirst Pastes data from clipboard to focused column only to rows only in the same parent in tree, starts always in the first row, if the pasted range contains more columns, an alert is displayed.
PasteToColFillFirst Pastes data from clipboard to focused column and to the next columns, starts always in the first row
PasteToColFillLevelFirst Pastes data from clipboard to focused column and to the next columns, to rows only in the same parent in tree, starts always in the first row
Undo Undoes the last grid modification (cell change, add row, delete row(s), move row(s), copy row(s)). Does not affect filter row and rows with NoUpload=’1’
UndoAll Undoes all modifications done since last save or accepting changes or reloading body or grid
Redo Does again the last undone action. It can be done only when between Undo and Redo was not done any other modification.
RedoAll Does again all undone actions. It can be done only when between Undo and Redo was not done any other modification.
ClearUndo Clears undo buffer.
Save Uploads changes to server and accepts them
Validate Validates data according to settings in Validate
Reload Reloads grid, cancels changes
Repaint Refreshes pages, when too many pages are displayed, the grid can slow down
Export Creates report for export and sends it to server
Print Shows printable version or grid and displays dialog for printing
ShowCfg Shows menu with grid configuration
ShowColumns Shows menu to choose columns visibility
ShowHelp Show TreeGrid user help page
GridResizeDefault Resizes main tag back to original size
ShowDetail ...F Shows data in detail grid for actual or focused row. It fails, if details grid already shows data for given row or the row is not master row.
RefreshDetail ...F Shows or refreshes data in detail grid for actual or focused row. It fails, if the row is not master row.
ClearDetail ...F Clears detail grid for actual or focused row. It fails, if the row is not master row.
AcceptEdit Ends editing, saves changed value, returns true when editing was finished, even if value was not saved
Changes are automatically accepted also by any change of focus by navigation actions – if you want to discard changes, call CancelEdit first.
CancelEdit Cancels editing, discards changes, return true when editing was finished
NewLine Puts LF into textarea
ChangeRadioRight Selects next radio button in Radio type focused cell. If none is selected, selects the first button. Usually used in edit mode for Right key.
ChangeRadioLeft Selects previous radio button in Radio type focused cell. If none is selected, selects the last button. Usually used in edit mode for Left key.
ChangeBool ...F Changes value in Bool type cell – checks or unchecks checkbox.
ShowLink ...F Navigates to URL in Link or Img type actual or focused cell.
ShowDefaults ...F Displays dialog with default values for the actual or focused cell
ShowCalendar ...F Displays dialog for selecting date for the actual or focused cell
ShowPopupMenu ...F Displays pop-up menu for the actual or focused cell
ButtonClick ...F Calls OnButtonClick event for actual or focused cell with Button type Button, Img or Html
DragGantt Changes Gantt chart content by mouse dragging. It can be used only for DragGantt event.
When mouse is above bar edge, it resizes the bar horizontally. When the bar is resized to width 0, it is deleted. The Flow bar edge has precedence to Main bar.
When mouse is above bar but not above its edge, it moves the bar horizontally. The Flow bar edge has precedence to Main bar and milestone. The flag has precedence to Flow bar.
When moving Main bar and creating dependencies is permitted, mouse must be always above the actual row, otherwise dependency is being created.
When mouse is above empty place, it creates and resizes new Main bar. If the Main bar already exists in the row, it creates and resizes new Flow bar.
When mouse is above milestone or flag, it moves the milestone or flag to the new position in the same row.
When mouse is above Main bar but not above its edge and dragging is done to another row, it connects dependency line with another Main bar.
Connects always from the first bar to the second bar. When dependency types (ss,sf,fs,ff) are permitted, the left half of bar specifies ‘s’, the right ‘f’.
You can specify <Actions DragGantt=’DragGantt’/> to provide all Gantt dragging to single drag or you can specify individual drag actions separately like
<Actions DragGantt="DragGanttResize OR DragGanttFlag" CtrlDragGantt="DragGanttNew" ShiftDragGantt="DragGanttDependency"/>
DragGanttResize Resizing bar action from DragGantt. It can be used only for DragGantt event.
When mouse is above bar edge, it resizes the bar horizontally. When the bar is resized to width 0, it is deleted. The Flow bar edge has precedence to Main bar.
DragGanttNew Creating new bar action from DragGantt. It can be used only for DragGantt event.
Creates and resizes new Main bar. If the Main bar already exists in the row, it creates and resizes new Flow bar.
DragGanttMove Moving bar, milestone or flag action from DragGantt. It can be used only for DragGantt event.
When mouse is above bar, milestone or flag, it moves the bar, milestone or flag to the new position in the same row.
DragGanttDependency Connects Gantt chart row with another row by dependency line, by mouse dragging. It can be used only for DragGantt event.
Connects always from the first Main bar to the second Main bar.
When dependency types (ss,sf,fs,ff) are permitted, the left half of bar and the left side specifies ‘s’, the right half of bar and right side specifies ‘f’.
DeleteGanttFlag Deletes one flag under mouse cursor
DeleteGanttFlow Deletes one Flow bar under mouse cursor
DeleteGanttMain Deletes Main bar if it is under mouse cursor
DeleteGanttDependency Deletes one dependency ending under mouse cursor. The dependency is under mouse cursor only next to the Main bar.
First are deleted incoming dependencies and if no incoming dependency under mouse cursor, the outcoming dependencies are deleted
DeleteGanttDependencies ...F Deletes all incoming and outcoming dependencies from actual or focused gantt cell.
DeleteGanttAll ...F Deletes all gantt items from the actual or focused gantt cell, including dependencies.
SetGanttPercent Changes % of completed to position under mouse cursor. Mouse must be above Main bar.
EditGanttResource Lets a user to edit resource text of main bar or milestone under mouse cursor
EditGanttFlag Lets a user to edit text of flag under mouse cursor
NewGanttFlag Adds new flag on mouse position and lets a user its text
NewGanttMilestone Adds new milestone on mouse position, only when the cell has neither main bar nor milestone
When deleting selected rows, shows confirm message also when are deleted rows shown (<Cfg ShowDeleted=’1’>)
ClickHeaderDelete = "UndeleteSelected OR (!this.ShowDeleted OR confirm('Do you want to delete all selected rows?')) AND DeleteSelected"
MS Excel editing behavior – Enter starts editing next cell below.
EnterEdit='AcceptEdit AND GoDownEdit AND StartEdit'
Enter='GoDownEdit AND StartEdit'
MS Excel editing behavior – Enter starts editing next cell below. For the last row it adds new one – works only when no fixed row is in footer.
EnterEdit='AcceptEdit AND (GoDown OR AddRowBelowF) AND StartEdit'
Enter='(GoDown OR AddRowBelowF) AND StartEdit'
Updates
Document created
Added actions RemoveRow and RemoveSelected
Added actions SortAscAdd and SortDescAdd.
Added Custom actions section and updated Calling actions from JavaScript
Added actions Indent and Outdent
Added Undo & Redo actions
Added Useful examples section
Added actions ExcludeRow and ExcludeSelected
Added Gantt actions