DbRecall Function (Usual) | |
Restore the current record if it has been marked for deletion.
Namespace:
XSharp.RT
Assembly:
XSharp.RT (in XSharp.RT.dll) Version: 2.19
Syntax FUNCTION DbRecall(
uArea AS USUAL
) AS LOGIC
public static bool DbRecall(
Usual uArea
)
Request Example
View SourceParameters
- uArea
- Type: Usual
Specifies the work area name or number for a table on which the operation must be performed.
Return Value
Type:
Logic
TRUE if successful; otherwise, FALSE.
Remarks
By default, this function operates on the currently selected work area.
It can be made to operate on an unselected work area by specifying
it within an aliased expression or by calling the overload that accepts a workarea
parameter (a workarea number or alias ).
DBRecall() performs the same function as the RECALL command.
For more information, refer to the DELETE and RECALL commands.
Tip |
---|
Logical records: Reinstating a deleted record affects the record's logical visibility if SetDeleted() is TRUE.
For more information, refer to the DBDelete() function and the DELETE and RECALL commands.
Shared mode: For a shared database, DBRecall() requires the current record to be locked.
|
Examples
The following example recalls a record if it is deleted and attempts to lock the record if successful:
1cLast := "Winston"
2DBUseArea(TRUE, "DBFNTX", "sales", "Sales", TRUE)
3Sales->DBSetIndex("LastName")
4IF Sales->DBSeek(cLast)
5 IF Sales->Deleted()
6 IF Sales->RLock()
7 Sales->DBRecall()
8 QOut("Record recalled")
9 ELSE
10 QOut("Unable to lock record...")
11 ENDIF
12 ENDIF
13ELSE
14 QOut("Not found")
15ENDIF
See Also