The RhoMobile Visual Studio Plug-in allows you to build Rhodes-based applications that target Windows Phone 8. The current version allows you to:
During installion (and removal) of the extension, a User Account Control prompt might appear in Windows. This is expected behavior; the current version of the extension installs for all users. |
Once the app is generated, a folder structure like the one below will appear in your workspace in a folder with the name you gave your app.
The process above generates all the files and folders to define the structure of your new application. This structure is the same as when creating an app using RhoStudio. However, ro run your new Windows Phone app you’ll have to add a ‘productid GUID’ to its build.yml
file. As seen above, the build.yml is located in the app’s root directory.
Using Visual Studio or any text editor, append the build.yml
file as follows:
wp: productid: 632621d0-5ecb-012e-2c97-482a1411c191
RhoMobile includes Rhom, a database object mapper (ORM) that provides a powerful high level interface to an on-device SQLite database. Rhom works hand in hand with the RhoConnectClient to enable two-way synchronization between your application and a RhoConnect server.
To create a data model:
This will automatically generate a folder and the corresponding files for handling CRUD operations for the model. For a better understanding of data models, please refer to the RhoMobile Data Handling Guide.
Since RhoMobile apps employ HTML, CSS and JavaScript to define the user interface and application behavior, a Windows Phone 8 app can be designed with a WP-native UI (a.k.a. ‘Metro’ by using one of these Metro-like frameworks:
Follow the instructions that accompany the framework you’ve chosen to replace the default.
Building RhoMobile apps requires an account on Rhomobile.com and that the user be logged in. This must be done via RhoMobile.com or RhoStudio before your build is attempted; no dialog or log-in prompt will appear within Visual Studio. |
Now that you’re now ready to build and launch your app, you must select from following build configuration options:
RhoSimulator builds and launches the app in RhoSimulator, a Webkit-enabled window that displays your app along with a Web Inspector tool to help facilitate debugging
Device deploys the app to your Windows Phone 8 device connected to the development machine for on-device debugging using Visual Studio or web inspector tools
Emulator launches the app in the Windows Phone 8 emulator provided by Microsoft
RhoSimulator is recommended while initially building your app's UI and establishing its basic behavior; it is the fastest method for testing and debugging web apps. |
To launch your new application in the RhoSimulator:
To run your the app in RhoSimulator from the command line, execute the following command:
$ rake run:wp8
The host computer’s keyboard can be used with the Windows Phone 8 emulator, but is disabled by default. To enable it, press the PgUp key or the PAUSE/BREAK key. While the host keyboard is enabled, device rotation simulation is disabled. To rotate the device in the emulator, you must first disable the keyboard by pressing the PgDown key. MSDN has more information about host keyboard use with the WP8 emulator.
$rake run:wp8:device
When running on device you may need to disconnect USB cable from device to see log |
The following features are on the Visual Studio Plug-in roadmap:
Related Resources