Вы находитесь на странице: 1из 6

Chapter 9

Each zip file contains an example project from Chapter 9. These projects have been tested with versions
2.2.1 and 2.3.
Projects

Chap09_Employee.zip: This is the employee database example presented in Section 9.1; the MBO
was introduced in Section 7.3.1.

Chap09_Customer.zip: This is the customer/sales order database example presented in Section 9.2;
the MBOs were introduced in Section 7.7.

Chap09_Accounts.zip: This is the example for general ledger account balances from SAP presented in
Section 9.3; the MBO was introduced in Section 7.3.3.

Chap09_Notification: This is the sales order notification database example presented in Section 9.4.

Installation
1. Unzip the file, which contains a project folder.
2. Copy the project folder to the Workspace.
3. Select FILE IMPORT EXISTING PROJECTS INTO THE WORKSPACE.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.

Database Files
All of the database files are part of My Sample Database. These can be started by logging onto the
Unwired Server:
1. Open the Windows command prompt and change to Sybase directory:
C:\Sybase\UnwiredPlatform\Servers\UnwiredServer\bin.
2. Run the following command to install the sampledb server as a Windows service in auto-start
mode: sampledb.bat install auto.

Chapter 10

The zip file contains an example project from Chapter 10. This project has been tested with version 2.3.
Projects

Chap10_Interface.zip: This project includes all of the examples described in the book.
Installation
1. Copy the project archive file to a folder.
2. Select FILE IMPORT EXISTING PROJECTS INTO THE WORKSPACE.
3. Select the archive file.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.

Database Files
All of the database files are part of My Sample Database. These can be started by logging onto the
Unwired Server:
1. Open
Windows
Command
Prompt
and
change
to
Sybase
directory:
C:\Sybase\UnwiredPlatform\Servers\UnwiredServer\bin.
2. Run the following command to install the sampledb server as a Windows service in auto-start
mode: sampledb.bat install auto.
Known Issues
This project was initially created with the ramp-up version of the Sybase Mobile SDK; as a result, the
JQuery map plugin example does not work. The Chapter 17 sample code includes another method for
accessing Google maps.

Chapter 11

The zip file contains an example project from Chapter 11. The project consists of five apps. The apps
have been tested with version 2.3.
Projects

Chap11_Function.zip: This project includes all of the examples described in the book.
Apps

Chap11_TwoCustomActions_23.xbw: Demonstrates the postage example using two custom actions.

Chap11_OneCustomAction_23.xbw: Demonstrates the postage example using one custom action.

Chap11_cache_23: Demonstrates the postage example caching choice control options.

Chap11_SUPStorage_23.xbw: Demonstrates the use of SUPStorage.

Chap11_Credentials_23.xbw: Demonstrates the use of dynamic credentials.

Installation
1. Copy the project archive file to a folder.
2. Select FILE IMPORT EXISTING PROJECTS INTO THE WORKSPACE.
3. Select the archive file.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.
Database Files
Although the examples in the book uses tables for the Microsoft Northwind SQL Server database, all of
the database tables in the sample project are part of My Sample Database. These can be started by logging
onto the Unwired Server:
1. Open
Windows
Command
Prompt
and
change
to
Sybase
directory:
C:\Sybase\UnwiredPlatform\Servers\UnwiredServer\bin.

2. Run the following command to install the sampledb server as a Windows service in auto-start
mode: sampledb.bat install auto.
To complete the postage example you will need to generate the table and the data in the table in the
sample database:
1. In the Workspace Navigator, drill into DATABASE SCHEMAS DBA TABLE and open Table_My
Sample Database_sampledb_Postage_ddl.sql.
2. Choose EXECUTE ALL on the DATABASE TOOLS menu.
3. In the Workspace Navigator, open Postage_data.sql.
4. Choose EXECUTE ALL on the DATABASE TOOLS menu.

Chapter 13

The zip file contains an example project from Chapter 13. The project consists of one app but has two
projects. The apps have been tested with version 2.1.3.

Projects

Chap13.zip: This project is a mobile application project containing an MBO based on the customer
table from the sample database.

Chap13_Android.zip: This is an Eclipse-based Android project.

Installation
The mobile application project:
1.
2.
3.
4.
5.

Copy the Chap13.zip project archive file to a folder.


In the Sybase Mobile SDK, select FILE IMPORT EXISTING PROJECTS INTO WORKSPACE.
Select the archive file.
Browse for the WORKSPACE folder, select the new project folder, and click FINISH.
Deploy the package to the default domain on your Unwired Server.

The Android project:


1. Copy the Chap13Android.zip project archive file to a folder.
2. In Eclipse, select FILE IMPORT EXISTING PROJECTS INTO WORKSPACE.
3. Select the archive file.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.
5. Open MainActivity and modify the server properties.
In the SCC:
1. Create a user (e.g., PreconfiguredLoginModule) in the admin security profile (AUTHENTICATION
tab):
a. User name: chap13User

b. Password: mobile
2. Run the Android app.
3. Once you see CONNECTED in the LogCat view, click SYNC.
4. If you see the error "Application settings are not available, close the app and restart it on the
device or emulator.

Chapter 14

The zip file contains an example project from Chapter 14. The project consists of one app but has two
projects. The apps have been tested with version 2.1.3.

Projects

Chap14.zip: This project is a mobile application project containing a MBO based on the customer
table from the sample database.

Chap14.xcodeproj.zip: This is an Xcode-based iOS project.

Installation
The mobile application project:
1. Copy the Chap14.zip project archive file to a folder.
2. In the Sybase Mobile SDK, select FILE IMPORT EXISTING PROJECTS INTO WORKSPACE.
3. Select the archive file.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.
5. Deploy the package to the default domain on your Unwired Server.
iOS Project
1. Unzip the Chap14.xcodeproj.zip project archive file to a folder.
2. In Xcode, select FILE OPEN.
3. Select the unzipped folder.
4. Open ConnectionController.m and modify the server properties.
In the SCC:
1. Create a user (e.g., PreconfiguredLoginModule) in the admin security profile (AUTHENTICATION
tab):
a. User name: chap14User
b. Password: mobile
2. Run the iOS app.
3. If you encounter the error "RuntimeException: Failure in getConfigProperty," close the app and
select RESET CONTENT AND SETTINGS from the iOS Simulator menu. Rerun the app.

Chapter 15

The zip file contains the example project from Chapter 15. This project has been tested with version 2.1.3.
Project

Chap15_MobileAnalytics.zip: This is the MAKit example presented in Chapter 15.


Installation
1. Unzip the file, which contains a project folder.
2. Copy the project folder to the Workspace.
3. Select FILE IMPORT EXISTING PROJECTS INTO THE WORKSPACE.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.
Database Files
All of the database files for this project can be created by running the three SQL files that are included in
the project:

RevenueByY.sql

RevenueBtM.sql

RevenueBtQ.sql
To run these SQl files, double click on the file, right-click, and then select EXECUTE ALL.

Chapter 17

The zip file contains an example project from Chapter 17. The project consists of two apps that have been
tested with version 2.3.
Projects

Chap17.zip: This project includes all of the examples described in the book.
Apps

Chap17_StandardApp_23.xbw: The standard app.

Chap17_CustomApp_23.xbw: The custom app.

Installation
1. Copy the project archive file to a folder.
2. Select FILE IMPORT EXISTING PROJECTS INTO THE WORKSPACE.
3. Select the archive file.
4. Browse for the WORKSPACE folder, select the new project folder, and click FINISH.

Database Files
Although the example in the book uses tables for the Microsoft Northwind SQL Server database, all of
the database tables in the sample project are part of My Sample Database. These can be started by logging
onto the Unwired Server:
1. Open
Windows
Command
Prompt
and
change
to
Sybase
directory:
C:\Sybase\UnwiredPlatform\Servers\UnwiredServer\bin.
2. Run the following command to install the sampledb server as a Windows service in auto-start
mode: sampledb.bat install auto.
To complete the postage example you will need to generate the table and the data in the table in the
sample database:
1. In the Workspace Navigator, drill into DATABASE SCHEMAS DBA TABLE and open each file.
2. Choose EXECUTE ALL on the DATABASE TOOLS menu.
3. After generating the tables, drill into DATABASE DATA and open each file.
4. Choose EXECUTE ALL on the DATABASE TOOLS menu.
To use Google maps, be sure to insert the following script element in the generated HTML files after
generating the app:
<script type="text/javascript"
src="http://maps.google.com/maps/api/js?sensor=false&libraries=places"></script>

Вам также может понравиться