08-24-2012 10:04 PM
I am getting a alert in starting in emulator using phone gap technology in android.
"Exception building coredova js globals: ReferenceError: can't find variable: org for key"exec".
actually i don't understand why this come.same code works on blackberry.
please help
Solved! Go to Solution.
08-25-2012 04:00 AM
Hi. Do you use the same Phonegap/Cordova for both platforms? You shouldn't since platforms might work different and that's why Phonegap/Cordova offers different files for all the supported platforms.
08-26-2012 04:05 AM
can you please give me a sample of scrollable list fixed height in android .
?
08-26-2012 09:06 AM
Hi ravi1989,
using Phonegap/Cordova has nothing to do with creating a scrollable list on either Android or BlackBerry, Phonegap/Cordova is mainly providing an interface to the underlying hardware to use the same function calls for eg. accessing the fileSystem of the device. So you write the source code only once and do not need to write it for each platform.
For your scrollable list you asked again and again here you might need to let us know how it should look like. Have you tried bbUI.js, jQuery mobile or any other framework that might be helpful for mobile UIs?
Also have a closer look to iScroll for scrollable lists. I used it to build scrollable list with various heights on iOS, PlayBook and Android devices and it is working well for me. There are examples to get started with iScroll on the page too.
08-26-2012 10:52 AM
Actually I am a beginner i don't know how to make scrollable list but i make scrollable list which is working fine in blackberry touch device, but when i run same code in android list is not scrolling , i will share my code.
with simple example..
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitiona
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Departure Schedule</title>
<link href="style/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="script/common.js"></script>
<script type="text/javascript" src="script/soapclient.js"></script>
<script type="text/javascript" src="script/jquery.min.js"></script>
<script type="text/javascript" src="iscroll.js"></script>
<script type="text/javascript">
function GetDepartureStationDashboard_callBack()
{
//document.getElementById('loadingImg').style.visi
var tabledata = "";
tabledata += "<table>";
for (var i = 0; i < 20; i++)
{
tabledata += "<tr id="+i+">";
tabledata += "<td >"+ i+ "</td>";
tabledata += "</tr>";
}
tabledata += "</table>";
document.getElementById("mainBodyDiv").innerHTML = tabledata;
}
</script>
</head>
<body onload="GetDepartureStationDashboard_callBack()">
<div id="wrapper">
<div class="login_cont">
<div class="home_icon"><a href="index.html"><img src="images/back-icon.png" alt="Home" title="Home" /></a></div>
<h1 class="fr">Departures</h1>
<div class="cl"></div>
<div class="mid_cont">
<div class="grid_cont">
<div class="heading_bar">
<h1 class="fl" id="headingcontent"></h1>
<input name="" type="button" class="heading_btn fr" value="Change" onclick="location.href='index.html'"/>
<div class="cl"></div>
</div>
<div>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="30%">PLATFORM NO.</td><td width="30%">STD - ETD</td><td width="35%">NEXT STATION</td><td width="5%">STATUS</td>
</tr>
</table>
</div>
<div class="scroll-pane" id="mainBodyDiv">
</div>
<div class="grid_error"><img src="images/help-icon.png" /> Departure Schedule</div>
</div>
</div>
</div>
</div>
<input type="hidden" name="hdnStationName" id="hdnStationName" value="" />
</body>
</html>
**************************************************
.scroll-pane
{
width: 100%;
height: 150px;
z-index:1;
overflow: auto;
position: relative;
}
.scroll-pane table tr:hover
{
background:#dbe3ec;
}
can you do some change so that it will run on both platform android or blackberry touch device\
THANKS
NAVEEN
08-26-2012 11:44 AM
I attached a sample that has a scrollable list using your source code. I changed some lines of code but the scrollable list also should work like you expect to. The list on the BB SmartPhone looks like this for now and same on Android device. This is broken down from the examples provided on the iScroll website, so to change styles and position of the scrollbar have a closer look there.
08-26-2012
11:50 AM
- last edited on
08-26-2012
10:03 PM
by
jakoby4204
thanks can you give me your ID <removed>, please add me
EDIT: Personal Information such as e-mail is prohibited for your security. Please review User Guidelines under section "Be careful."
08-26-2012 11:53 AM
08-26-2012 11:55 AM
NP. Hope it is a solution for you.
BTW: there is a button to add source code to your posts for more readability ![]()
08-26-2012 12:03 PM
can you explain ..what is the use of this line
var myScroll = new iScroll('mainBodyDiv', {snap: 'tr', scrollbarClass: 'myScrollbar' });.
i know mainBodyDiv is Id of div
but what is scrollbarClass..?
and what is myScrollbar..?