|
|
|
|
- Accessing a database found on the Mobile Device (Pocket PC)
cdbReadLast (Function) In french: cdbLitDernier Positions on the last file record and reads this record. In most cases, cdbReadLast is used to position in the data file in order to perform a read loop with cdbReadPrevious. After the call to cdbReadLast, if the data file is empty: - no read operation is performed,
- cdbOut returns True.
Caution: From Windows Mobile 5, the access to a standard database (tasks, contacts, appointments, ...) can no longer be performed from a Windows application (and therefore from a standard WINDEV application). | | | | | Accessible from the PC | Accessible from the simulator | Accessible from the Mobile Device (Pocket PC) | CDB database | Yes | Yes | Yes | Standard database | No | No | Yes |
// Read the last record found in Customer file cdbReadLast("MyDatabase", "Customer") // Record outside the file? WHILE cdbOut("MyDatabase", "") = False // Process the record cdbReadPrevious("MyDatabase", "") ... END
// Standard "Contacts" database // Read the last record cdbReadLast("", cdbContact) // Record outside the file? WHILE cdbOut("", cdbContact) = False // Process the record cdbReadPrevious("", cdbContact) ... END
Syntax
<Result> = cdbReadLast(<Database> , <Data file>)
<Result>: Boolean - True if the function was successful,
- False otherwise. If an error occurs, you can get the details of the error with ErrorInfo.
<Database>: Character string (with quotes) - Name of database that was opened by cdbOpen,
- Empty string ("") to handle one of the standard databases of the Mobile Device (tasks, contacts, ...).
<Data file>: Character string (with quotes) or constant Data file to use. This parameter corresponds to:- the name of data file to use.
- the constant corresponding to one of the standard databases:
| | cdbContact | "Contacts" database | cdbTask | "Tasks" database | cdbAppointment | "Appointments" database |
If this parameter is an empty string (""), the cdbReadLast function will handle the last data file used by the last database management function of the Mobile Terminal (function starting with the letters cdb). Remarks Accessing a database found on the Mobile Device (Pocket PC) The table below presents the actions that must be performed to access a database found on Mobile Device: | | | | Database | Standard database (tasks, contacts, appointments, ...) | Standard WINDEV application | - Establish a connection between the current computer and the Mobile Device (ceConnect).
- Open the database to use (cdbOpen).
| Establish a connection between the current computer and the Mobile Device (ceConnect). | WINDEV Mobile application | Open the database to use (cdbOpen). | No specific action is required. | Reminder: From Windows Mobile 5, the access to a standard database (tasks, contacts, appointments, ...) can no longer be performed from a Windows application (and therefore from a standard WINDEV application).
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|