Select to view content in your preferred language

RE: ARCGIS Server javascript API CodeAssist Plugin for Aptana studio 3.0version

675
4
08-19-2012 04:36 AM
GaneshSolai_Sambandam
Regular Contributor
HI GIS folks
Can you anyone tell me how to reference the CodeAssist Plugin in Aptana studio 3 version.
Referencing the Javascript API plugin in Aptana studio 2.0 version was straightforward  and easy. With Version 3.0, I don't know how to add the Javascript API 3.1 in Apatna studio 3.0 and this made me difficult to reference them.

Any help, you would be much appreciated.

Regards
Ganesh
0 Kudos
4 Replies
balrajmone
Deactivated User
It�??s working for me when I write HTML and java script files separately.
But not working if HTML page contains both HTML tags & Java script.

1. Download the zip file that contains the VSDoc file for the version of the ArcGIS API for JavaScript you are using.
2. Drag the VSDoc file into your Aptana project.
3. Write HTML and java script files separately
4.  working even without using <script type="text/javascript" src="jsapi_vsdoc_v31.js"></script> in HTML file
0 Kudos
GaneshSolai_Sambandam
Regular Contributor
thanks balaji for your reply. It works fine.

But there is another problem for me.
dojo.require intellisense is not working even if i write my code separately in *.js file (as you mentioned in the previous post).

So, I have to manually type them without using intellisense.

In addition, If I use dojotype property to reference the dijit.layout.BorderContainer on my HTML page, the intellisense feature doesn't recognize this feature on my HTML page.

Is there way to get around this problem.

Do we need to reference the dojolibraries on our HTML page on top  <script type="text/javascript" src="jsapi_vsdoc_v32_2010.js"></script>

Regards
Ganesh
0 Kudos
JakeSkinner
Esri Esteemed Contributor
Hi Ganesh,

I haven't been able to get the intellisense to work for HTML files, but I have for Javascript files by copying the attached 'dojo.1.6.0.sdocml' to the project.
0 Kudos
GaneshSolai_Sambandam
Regular Contributor
HI Jskinner
Thank you very much for dojolibrary files. However, in my last post, I asked a question on dojotype property, you didn't answer that question. I am using Aptana studio 3.0 to run my application. when I include a dojotype property in the html page of the <div> tag in Aptana Studio, this element / property is not recognized in Aptana studio. Can you please clarify this one. For your reference I have included the code the below. Please go through them and get back to me, if I am missing relevant code. Your help is much appreciated and expecting your reply with anticipation.

Thanks
Ganesh

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<meta http-equiv="X-UA-Compatible" content="IE=7,IE=9" />

<!--The viewport meta tag is used to improve the presentation and behavior of the samples on iOS devices-->

<meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no"/>

<title> World Street Map</title>

<link rel="stylesheet" type="text/css" href="http://serverapi.arcgisonline.com/jsapi/arcgis/3.2/js/dojo/dijit/themes/claro/claro.css">
<link rel="stylesheet" type="text/css" href="http://serverapi.arcgisonline.com/jsapi/arcgis/3.2/js/esri/css/esri.css" />


<script type="text/javascript">
var djConfig = {parseOnLoad: true};
</script>


<script type="text/javascript" src="http://serverapi.arcgisonline.com/jsapi/arcgis/?v=3.2"></script>
<script type="text/javascript">
dojo.require("esri.map");
dojo.require("dijit.dijit");
dojo.require("dijit.layout.BorderContainer");
dojo.require("dijit.layout.ContentPane");
var map;

function init()
{

var initExtent = new esri.geometry.Extent({"xmin":-17731,"ymin":6710077,"xmax":-12495,"ymax":6712279,"spatialReference":{"wkid":102100}});
map = new esri.Map("map",{extent:initExtent});
//Add the world street map layer to the map. View the ArcGIS Online site for services http://arcgisonline/home/search.html?t=content&f=typekeywords:service
var basemap = new esri.layers.ArcGISTiledMapServiceLayer("http://server.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer");
map.addLayer(basemap);
dojo.connect(map, 'onLoad', function(theMap) {
//resize the map when the browser resizes
dojo.connect(window, 'resize', map,map.resize); });

}

dojo.addOnLoad(init);
</script>

</head>

<body class="claro">
<div id="mainWindow" dojotype="dijit.layout.BorderContainer" gutters="false" style="width: 100%, height: 100%;" >


<div id="map" dojotype="dijit.layout.ContentPane" region="center">
</div>



</div>

</body>
</html>
0 Kudos