Development of Windows Mobile Applications (Part 2)

0
147
3 min read

Now let us see how to deploy it on Windows Mobile Device. For deploying the application on device you need to have ActiveSync installed.

There are two ways in which application can be deployed on to the device.  First option is to connect the device to the Development machine via USB. ActiveSync will automatically detect it and you can click on FreePBX 2.5 Powerful Telephony Solutions on the top bar. And this time select option “Windows Mobile 6 Professional Device”.

FreePBX 2.5 Powerful Telephony Solutions

But then this approach is useful when you want to test/deploy and use the application yourself. What if you want to distribute it to others? In that case you need to create an installation program for your Windows mobile application. The installation file in the Windows Mobile world is distributed in the form of a CAB file. So once we have done with application we should opt for option 2 of creating a CAB file (A CAB file is a library of compressed files stored as a single file).

Creating CAB File

Creating a CAB file itself is a new project. To create CAB project right click on the solution and select the option New Project as shown below.

FreePBX 2.5 Powerful Telephony Solutions

Clicking on New Project option will open Add New Project Wizard. Select option Setup and Deployment under Other Project Types on the left hand menu. Then select option Smart Device CAB Project on right hand side as shown below. We have named this project as MyFirstAppCAB.

FreePBX 2.5 Powerful Telephony Solutions

Click OK and MyFirstAppCAB project is created under the solution a shown.

FreePBX 2.5 Powerful Telephony Solutions

Now to add files to the CAB, right click on the Application Folder under File System on Target Machine and select option Add-> Project Output as shown.

FreePBX 2.5 Powerful Telephony Solutions

On selecting Project Output option, the following screen will popup. Depending upon the requirement, select what all needs to be compressed in CAB file. For this example we require only output, hence will select option Primary output.

FreePBX 2.5 Powerful Telephony Solutions

Now right click on CAB project MyFirstAppCAB and select option Build.

FreePBX 2.5 Powerful Telephony Solutions

CAB file with name MyFirstAppCAB will be created at the location MyFirstAppMyFirstAppCABDebug.

Now let us see how we can deploy this CAB file on emulator and run the application. Click on Tools on the top bar and select option Device Emulator Manager.

FreePBX 2.5 Powerful Telephony Solutions

This will open a Device Emulator Manager as shown below. Select option Windows Mobile 6 Classic Emulator. Right click and select option Connect.

FreePBX 2.5 Powerful Telephony Solutions

Windows Mobile Emulator will start and on Device Emulator Manager you can see FreePBX 2.5 Powerful Telephony Solutions to left of Windows Mobile 6 Classic Emulator as shown below.

FreePBX 2.5 Powerful Telephony Solutions

Next step is to Cradle.

If you are attempting to cradle for the 1st time, then you need to setup ActiveSync. To setup ActiveSync, double click on FreePBX 2.5 Powerful Telephony Solutions on right bottom on Task bar. Microsoft ActiveSync will open up, select option File -> Connection Settings as shown in figure below.

FreePBX 2.5 Powerful Telephony Solutions

Connection Settings window will be open up as shown below. Check the option Allow Connections to one of the followings and then from the drop down select the option DMA.

FreePBX 2.5 Powerful Telephony Solutions

After connecting Windows Mobile 6 Classic Emulator using Device Emulator Manager, again right click and select option Cradle as shown below. Cradle will start ActiveSync and make Emulator work as device connected using ActiveSync.

FreePBX 2.5 Powerful Telephony Solutions

On successful connection you can see FreePBX 2.5 Powerful Telephony Solutions on the left of option Windows Mobile 6 Classic Emulator on Device Emulator Manager as shown.

FreePBX 2.5 Powerful Telephony Solutions

LEAVE A REPLY

Please enter your comment!
Please enter your name here