Tuesday, October 23, 2012

Simple x y dojo chart example

This is a very simple x, y, chart using Dojo and sourcing the js and css from Google.  Copy the next part and save as a html file.

<!DOCTYPE html>
<html >
dojoConfig = "{parseOnLoad: true}"></script>
<link rel="stylesheet" type="text/css" href="http://ajax.googleapis.com/ajax/libs/dojo/1.8/dijit/themes/claro/claro.css"/>

<script type="text/javascript" >
dojo.require( "dojox.charting.Chart" );
dojo.require( "dojox.charting.axis2d.Default" );
dojo.require( "dojox.charting.plot2d.Lines" );

    var chart1 = new dojox.charting.Chart("simplechart",{title: "Basic XY chart" });
    chart1.addPlot("default", {type: dojox.charting.plot2d.Lines});
    chart1.addAxis("x", {title: "X axis", titleOrientation: "away"});
    chart1.addAxis("y", {vertical: true, title: "Y axis"});
    chart1.addSeries("Series 1", [1, 2, 2, 3, 4, 5, 5, 7]);
<body class="claro">
    <div id="simplechart" style="float:left; width: 350px; height: 350px; margin: 5px auto 0px auto;"></div>



Tuesday, August 7, 2012

Issues in Beginning RhoMobile

Here I'm listing a few mistakes/typos in the book Rhomobile Beginner's Guide.

Chapter 4

Code for cancel button on the filter_employee_form.erb, chapter 4, incorrectly takes you to the index of employees, when It should take you back to the home page. Replace :

<a class="cancel" href="<%= url_for :action => :index %>">Cancel</a>


<a class="cancel" href="<%= Rho::RhoConfig.start_path %>">Cancel</a>

Also latest ruby practice is to use link_to instead of <a href style.

Creating a RhoSync application.

Should say where to run the rhosync application. Also rhosync is now replaced by rhoconnect. So starting rhosync with rake is now starting rhoconnect with rake.

Installing the Rhodes translator gem

You must run gem install from the ruby folder or it won't work.

Thursday, April 19, 2012

Fixing RhoMobile build problems to android device.

Android SDK location.

Make sure you don't install it with any spaces.

Version of Android SDK

I had to install 2.3 before it would compile without complaining about missing getNumberOfCameras()

And delete xlargeScreen

Wednesday, April 18, 2012

Connectify connecting problems using android phone

I changed my laptop and installed Connectify onto it. Then I tried to connect with my Atrix to the WiFi. It saw the hotspot but whenever I tried to connect the phone would say 'obtaining ip address' for about 2 minutes, then abort the connection. Another laptop could connect to the Connectify hotspot so the issue was on the phone.

Solved the issue by going into the WiFi settings on android, pressing the menu button, choosing 'Advanced' and selecting 'Enable Auto IP'. Then it connected! Hooray!