The ADOCE Sample demonstrates a simple application that uses ADOCE, the ADO programming interface for Windows CE development. This application allows you to start the sample database running on the network database server, and access data using SQL statements.
You must have Visual Basic installed on your Windows CE device to use the ADOCE sample.
The source code for this sample can be found in on your computer in samples-dir\SQLAnywhere\ce\adoce_sample.
You can load this project in eMbedded Visual Basic from the following location on your computer: samples-dir\SQLAnywhere\ce\adoce_sample.
NoteIn the ADOCE Sample user interface, SQL statements must be entered on a single line. |
Start the ADOCE Sample by tapping Start > Programs > SQLAny10.
Tap ADOCE Sample.
Tap Connect.
The sample database starts on a network database server. The Server Messages window appears briefly, then disappears.
Tap Execute SQL to execute the default SQL statement, SELECT * FROM Employees
.
All the data from the Employees table appears in the data window.
Navigate through the data in the Employees table using the scroll bar on the side of the data window.
Access a more specific range of data by typing SELECT EmployeeID, Surname FROM Employees
and then tapping Execute SQL to execute the statement.
Scroll down to view the data, which appears below the data that is already displayed in the data window.
Access data from another table by typing SELECT * FROM Customers
in the Execute SQL field and then tapping Execute SQL.
Scroll down to view the data from the Customers table, which appears below the data that is already displayed in the data window.
Shut down the network database server by tapping Disconnect.
The ADOCE Sample disconnects, and the network database server automatically shuts down.
Close the ADOCE Sample by tapping the × in the top right corner of the window.