The Hybrid Web Container in this procedure is a
sample container provided with the Sybase Unwired Platform Mobile SDK installation.
Task
This example uses Eclipse as the development environment, but you can use
any development environment.
- Open Eclipse and select .
- Expand the General folder, choose Existing
Projects into Workspace, and click Next.
- Choose Select archive file,
browse to <UnwiredPlatform_InstallDir>\UnwiredPlatform\MobileSDK<version>\HybridApp\Containers\Android\,
and select Android_HWC_<version>.zip.
- Click Finish.
A Hybrid Web Container project folder is added to Workspace Navigator. You may
receive an error indicating that the source folder
gen
is missing. If so, add an empty folder named
gen
to the
src
folder in the project.
- Open the
local.properties
file in the main directory of the project. This file contains a non-commented line,
sdk.dir
=
<filepath>.
Verify
the <filepath> matches the filepath to your installation of the
Android SDK.
- If you receive an
Android
requires compiler compliance level 5.0 or 6.0. Found '1.4' instead. Please use
Android Tools > Fix Project
Properties
error, follow the instructions and then clean the project.
- If you receive errors of the type
…
must override a superclass
method,
make sure the Java compiler has its compliance set to 1.6.
- Right-click the
HybridWebContainer project and select
Properties.
- Go to the Java Compiler section
and
set
the Compiler compliance
level
to 1.6.
- Rebuild
the project.