|
|
|
|
|
- Overview
- Prerequisites
- Copying and pasting a row from a Table control into another Table control
- Remarks
- Programming
AAF: Pasting a row from one Table control into another
Table controls are used to view and manipulate data. In some cases, it may be useful for users to copy an entire row from one Table control and paste it into another. A specific Automatic Application Feature makes this possible. Prerequisites To make this Automatic Application Feature (AAF) available to end users, a few conditions must be met: - This feature is only available for Table controls populated programmatically.
- The Table control to paste into, as well as its columns, must be in edit mode.
- The two Table controls must be compatible, i.e., they must have the same number of columns, be of the same type, etc.
Copying and pasting a row from a Table control into another Table control To copy a row from one Table control to another: - In the first Table control, right-click the desired row and select "Copy row".
- In the second Table control, right-click where you want to paste the data and select "Paste entire row".
The current selection in the second Table control is immediately replaced with the copied data. Note: You can also use the Ctrl + C and Ctrl + V shortcuts. Remarks - You can also use the Ctrl + C and Ctrl + V shortcuts.
- All the WLanguage events of the target Table control and of its columns are executed on the pasted data. These include: entry, exit, modification, etc.
- It is also possible to copy and paste Table control rows between two WINDEV applications open at the same time.
A series of AAFxxx functions can be used to manipulate the "Paste entire row" option. Simply use these functions with the aafPasteEntireRow constant. | | AAFChangeCaption | Changes the text of the option that allows users to paste a row from one Table control into another Table control. | AAFDisable | Disable the context menu that allows users to paste a row from a Table control into another Table control. | AAFEnable | Re-enables the context menu that allows users to paste a row from a Table control into another Table control. | AAFExecute | Pastes a row from one Table control into another. The current row is replaced by the pasted row. |
Example: Copying a row from "TABLE_FullMenu" to "TABLE_CurrentMenu":
AAFExecute(TABLE_FullMenu, aafCopyRow)
Multitask(-1 s)
AAFExecute(TABLE_CurrentMenu, aafPasteEntireRow)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|