Error: Could not create and deploy an application with boundless sdk opengeo suite

I work on a web application with Boundless SDK opengeo 4.1, I used the tutorial and followed the exchange and advice on this forum but I have some problems about adding plugins and deploying the apps. I need help if someone here can help me. 1- I’ve already added all plugins I need for my project but I can’t add some plugins like gxp.Mesure, gxp.GoogleEarth 3D, gxp.FeatureGrid or Query Form which aren't enabled on the application. You can see below the application: ![enter image description here](http://i.stack.imgur.com/DPhD7.png) 2- I can’t make the package app for creating file.war to deploy with this application, I have a message error that you can see below: ![enter image description here](http://i.stack.imgur.com/prDjx.png) 3- Is there a plugin that allows to export data like an excel format for the application with SDK clients? Thanks !


ogr2ogr - Looping through files in a folder on a Mac

I am attempting to use OGR2ORG on Mac OS X to loop through 30 shapefiles, change their projection and save the files into a new directory. I am new to using Macs and the OGR2OGR command line environment. The original files are in /data/ChicagoBaseLayers/clipped. I would like the reprojected layers to go to /data/ChicagoBaseLayers/Projected. After navigating to the 'clipped' directory on the command line, I tried for %f in (*.shp) do ogr2ogr -t_srs EPSG:3857 -s_srs EPSG:4326 /Users/stevenchong/data/ChicagoBaseLayers/Projected/%f Users/stevenchong/data/ChicagoBaseLayers/clipped/%f but I get the error message: syntax error near unexpected token `(' What am I doing wrong?


I'm trying to create a table with spatial column in oracle and insert data into it. I'm using ArcSDE and Oracle. The version of Oracle is 11.2.0, the version of ArcSDE is 10.0. My create statement is:               CREATE TABLE sensitive_areas (area_id integer, name varchar(128),      area_size float, type varchar(10), zone sde.st_geometry);      And insert statement is:               INSERT INTO SENSITIVE_AREAS (area_id, name, area_size, type, zone)     VALUES (1, 'Summerhill Elementary School', 67920.64, 'school', sde.ST_PolyFromText('polygon ((52 28,58 28,58 23,52 23,52 28))', 0));      I've already added st_shaplib.dll and libst_raster_ora.dll to the environment variable EXTPROC_DLLS. My tnsname.ora:                   LISTENER_ORCL =       (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))               ORACLR_CONNECTION_DATA =       (DESCRIPTION =         (ADDRESS_LIST =           (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))         )         (CONNECT_DATA =           (SID = CLRExtProc)           (PRESENTATION = RO)         )       )          ORCL =       (DESCRIPTION =         (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))         (CONNECT_DATA =           (SERVER = DEDICATED)           (SERVICE_NAME = orcl)         )       )      My listener.ora:               SID_LIST_LISTENER =       (SID_LIST =         (SID_DESC =           (SID_NAME = CLRExtProc)           (ORACLE_HOME = D:\app\rainman\product\11.2.0\dbhome_3)           (PROGRAM = extproc)           (ENVS = "EXTPROC_DLLS=ONLY:D:\app\rainman\product\11.2.0\dbhome_3\bin\oraclr11.dll;D:\Program Files\ArcGIS\ArcSDE\ora11gexe\bin\st_shapelib.dll;D:\Program Files\ArcGIS\ArcSDE\ora11gexe\bin\libst_raster_ora.dll")         )       )          LISTENER =       (DESCRIPTION_LIST =         (DESCRIPTION =           (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))           (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))         )       )          ADR_BASE_LISTENER = D:\app\rainman      However, I got this error: ORA-28595: Extproc agent : Invalid DLL Path. What should I do? Thanks USER_LIBRARIES entry for ST_SHAPELIB is also correct: ST_SHAPELIB D:\Program Files\ArcGIS\ArcSDE\ora11gexe\bin\st_shapelib.dll Y VALID


Calculating Centroids with Zonal Geometry in ArcGIS

I have a shapefile containing polygons. Each polygon is defined by its postal code. I want to calculate the centroid of each polygon using Zonal Geometry. Sadly, for some polygons there are no centroids being calculated. It is the same when I use Zonal Statistics as Table. Some polygons seem to be ignored. There are no error messages. It would help if someone could point me in the right direction because right now I do not even know what to fix. I have ArcGIS 10.1. Thanks for any help!


Cloud points metrics with Terrascan

I need to extract from a las file statistics like percentile 95 height and others. Do you know how to do it with Terrascan? I can do it with FUSION, but I would like to do it with Terrascan.


image rectification with Mercator projection

I have written an image rectification function which allows a user to select 2 points on an image and 2 points on a map. The function will then rectify the image so it is translated, scaled and rotated to fit the two points on the map. The code I have written works perfectly along the equator. However this function 'breaks' when moving further north or south. The rotation and the scale are both wrong. I believe this is because of the Mercator projection I use which stretches along the latitude axis. I am unsure how to proceed. Is there a bit of math I am unaware of which will compensate for the stretching along the latitude? Or am I wrong in my assumption this is because of the Mercator projection? Below you will find the code I use:               // transformFromPoints is an array with the two coordinates on the image     // They are in lat long     var fromPointA = this.transformFromPoints[0];     var fromPointB = this.transformFromPoints[1];          // transformToPoints is an array with the two coordinates on the map     // They are in lat long     var toPointA = this.transformToPoints[0];     var toPointB = this.transformToPoints[1];          // This is the img we want to transform     var img = this.activeBaseMapImg;          // First update the anchor so the anchor is exactly at fromPointA     // The anchor defines the point around which the image will be drawn     // This is also the point around which the image is rotated.     var cornerPoints = img.getCornerPoints();     var xAnchorPos = M.Math.projectPointOnLine(fromPointA, cornerPoints[0], cornerPoints[1]);     var yAnchorPos = M.Math.projectPointOnLine(fromPointA, cornerPoints[0], cornerPoints[3]);          var xAnchorDir = M.Math.subVector2(xAnchorPos, cornerPoints[0]);     var xLineDir = M.Math.subVector2(cornerPoints[1], cornerPoints[0]);     var yAnchorDir = M.Math.subVector2(yAnchorPos, cornerPoints[0]);     var yLineDir = M.Math.subVector2(cornerPoints[3], cornerPoints[0]);          var xAnchor = xAnchorDir.x / xLineDir.x;     var yAnchor = yAnchorDir.y / yLineDir.y;          // Set the anchor at the fromPointA location     img.setAnchor({x: xAnchor, y: yAnchor});          // Move the image to the toPointA location     img.setPosition(toPointA);          var fromDirection = M.Math.subVector2(fromPointB, fromPointA);     var toDirection = M.Math.subVector2(toPointB, toPointA);          // Determine scale     var scale = toDirection.length() / fromDirection.length();          // Determine rotation     var fromAngle = Math.atan2(fromDirection.y, fromDirection.x);     var toAngle = Math.atan2(toDirection.y, toDirection.x);          var angle = fromAngle - toAngle;          // Perform rotation and scale     img.setRotation(img.rotation + angle);     img.setSize({width: img.size.width * scale, height: img.size.height * scale});      If you need any more information to help in answering this question, please let me know.


Can you create a CRS of superseded NSW Datum

I want to use a superseded projection (NSW integrated survey datum - referred to as ISG) because my main client utilises it. The projection is based on AGD66. We regularly receive survey files in this projection and need to prepare designs in this projection. Unfortunately no one I know, including surveyors, seems to know much about the ISG projection, let alone set up a CRS for it. When I import ISG data into an existing QGIS file, the files reproject fine and appear in the right location. However the coordinates are obviously incorrect, making it difficult to work with. Is there a way to extract and set a new datum based on data I know is already in ISG format? Thanks


Display Dolfin XML in Web Browser?

I got a mesh as Dolfin XML and would like to know if there is anybody that had some experiences with the web visualisation of it. Is it possible to convert in X3D?


How can I make a reference plane to measure surface volume?

I am looking to make a reference plane like the links below. I want to measure surface volume of an area in different elevation layer. I just need to know how to make the reference plane in ArcGIS 10.1 ! http://resources.arcgis.com/en/help/main/10.1/index.html#//00q900000037000000 Best, Mahnoush


Starting with OpenStreetMap for Android

My goal is to write an Android application where I could select a couple of points in the map and calculate shortest path between them based on my algorithms. I'm absolutely new to OSM and since googling doesn't give that much info as with Google Maps API for Android (which I can't use in this case due to lack of data that I can get), I have few questions:   1. What would be the best way for beginner to start with OSM - is there some all-uniting Android API that (everyone) starts with?   2. Is there some kind of official API documentation that I should follow?   3. How are routes' coordinates stored and how can I retrieve them?   4. Are there any really good tutorials that I should follow to start with developing my Android app?  \-- I know how stackexchange pages work but, seriously, googling didn't give me that much information, so here could be something like a links-how-to-start- with-OSM-for-Android list page with short explanation.


MapInfo - writing text using polylines

I am looking for a way to create text on a MapInfo layer using Polylines. So on a MapInfo layer, I need to create a line dataset, but I am after forming words - labelling items is not going to work for me. Are there any tools that can help do this? I have tried doing it freehand using a polyline, and a polyline with autonode mode selected, but frankly it looks rubbish


Make table views in ModelBuilder with Iterator

I'm trying to use the model as shown in the image to get 300 tables for the 300 points in the input feature class. I can get 300 viewshed rasters but can only get the table of the last point. It seems the model did create 300 tables, however, each table was named the same (vshed_0_View) even though I had put the "_%n%" in the output name, so the created tables were always overwritten by the next one. I had uncheck "Intermediate" for vshed_%n% so the obtained viewshed rasters were not deleted. I don't know what caused the problem. Does "Make table view" not work with Iterator? Are there any other ways to avoid being overwritten? Many Thanks!![enter image description here](http://i.stack.imgur.com/iRuvs.jpg)


Accessing File Geodatabase to convert to shapefiles using ArcObjects?

The end result of what I'm trying to do is convert a FGDB into a folder of shapefiles. To do this, I need access to all the data I'd expect to see in a shapefile. Once I get all the information I need from the file geodatabase, it should be really easy. I am stuck on trying to _read the file geodatabase spatial data (Xs and Ys)_ UPDATE: Using the snippet of code posted by Rich Wawrzonek below, I can read the names of the datasets. Now I need to know how to read the Xs and Ys of each dataset!                   IEnumDataset enumDataset = iwrk.Datasets[esriDatasetType.esriDTFeatureClass];         IDataset dataset;         while ((dataset = enumDataset.Next()) != null)         {              //Do something with the feature class here              Console.WriteLine(dataset.Name);         }


How do I fill gaps in a raster to zero value cells?

I am trying to add some forest elevations to a DEM using ArcView. I have converted a polygon feature class of a forest into a raster with the same resolution as my DEM. Then I reclassed the forest raster to 15 (the height of the forest). This has resulted in a patchy raster with gaps of nothing between. To get a raster that covers the entire study area I created a constant raster with the extent of the forest polygon and containing the value of 0. when I add the two rasters together I end up with a replica of my forest raster rather than a raster with forest cells of value 15 and 0 values everywhere else. Any Ideas of how to fill in the gaps between my forest cells?


QGIS2.4.0: Cannot import qgis module in python "from qgis._core import * \n DLL Load Error"

Having some trouble importing qgis into python. I'm very new to python so it could be a simple mistake. The path seems to be correct. It gets this far:                   File "<stdin>", line 1, in <module>         File "qgis\__init__.py", line 36, in <module>         from qgis.core import QgsFeature, QgsGeometry         File "qgis\core\__init__.py", line 1, in <module>         from qgis._core import *         ImportError: DLL load failed: The specified module could not be found.


Detecting esri markers within certain distance using ArcGIS JavaScript API?

I have a set of coordinates that is loaded from database. I would like to detect all the loaded markers that are close to each others which is within a certain distance. so the code is something like               function locatePOI() { // Places of Interest             var Grid_Table = document.getElementById('PrimarySchoolDGV');                       var xmlhttp=new XMLHttpRequest();             xmlhttp.open("GET", "/Foreigners@SG/WebService.asmx/getPlacesOfInterests", false);             xmlhttp.send();             var xmlDoc = xmlhttp.responseXML;             var xmlalbums = xmlDoc.documentElement.getElementsByTagName("PlacesOfInterest");                  $.each(xmlalbums, function () {                 testindex = 0;                 var school = $(this).find("Name").text();                 var address = $(this).find("Address").text();                 var postalcode = $(this).find("PostalCode").text();                 var cat = $(this).find("Category").text();                 var incidentI = "";                      coordX = $(this).find("X").text();                 coordY = $(this).find("Y").text();                      var point = new esri.geometry.Point({ "x": coordX, "y": coordY, "spatialReference": { "wkid": 3414} });                     **if(pointsbetweeneachother < 3km)         {         // do something here         }**                                var symbol = new esri.symbol.PictureMarkerSymbol('images/icons/Interest-icon1.png', 25, 25);                           //symbol = new esri.symbol.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_CIRCLE, safetyLevelRadiusSize * 10, new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, new dojo.Color([r, g, b, 0.5]), 10), new dojo.Color([r, g, b, 0.9]));                 var infoTemplate = new esri.InfoTemplate();                      infoTemplate.setTitle("   " + school);                 infoTemplate.setContent("Food Establishments : " + school + "
"                             + "Address: " + address + "
"                             + "PostalCode: " + postalcode + "
"                            + "Category: " + cat + "
"                                 );                      var graphic = new esri.Graphic(point, symbol);                 map.graphics.add(graphic);                 graphic.setSymbol(symbol);                 graphic.setInfoTemplate(infoTemplate);                  }             );         }      can anyone help me out?


Python: Ray-trace a WGS84 point with heading and distance

One of my services defines geofences for a mobile app. The geofences consists of a lat/lon pair and radius in meters, in `JSON`, e.g.:               {         "geofenceId":"geofence_b39da38cff7be4b4693cbc31b2394bbb",         "latitude":32.083611,         "longitude":34.806111,         "radius":15000.0     }      I would like to display these geofences in KML. Alas, KML files don't feature circles, so I have to approximate using a polygon with `n` vertices. Each vertex location is the head of a vector originating at the centre of the circle, whose length is the circle radius and has a given heading: ![enter image description here](http://i.stack.imgur.com/XUr6z.png) What's the Pythonic way to calculate `P2` from `P1`, `θ` and `radius`? **Update:** I've found some obvious solutions (like this), which assume that the earth is a perfect sphere. I calculated a circle with a radius of 15 Kilometers and 72 points. For each point, I've calculated the exact vincenty distance from the center. The minimum and maximum are:               14941.7356806     15014.5884245      The error is significant - a few dozen meters. I would like to find a solution that uses a better approximation. **Second Update:** I am trying to calculate ray tracing, which is `(P1_lat, P1_lon, radius, heading) -> (P2_lat, P2_lon)`. This is different from the distance between two given points, which can be easily done with geopy's vincenty formula.


How to use consistent symbology between multiple stretched rasters in ArcMap?

I have a series of continuous rasters representing the same phenomenon over time, so I need to use the same symbology across them all. So I set the stretched symbology of the first raster, with a color ramp from the min/max values: ![enter image description here](http://i.stack.imgur.com/cW4J8.png) Now in the second raster, I import the symbology from the first raster. Unfortunately, although the **labels** match, the actual **min/max values** are not the same as the first layer: ![enter image description here](http://i.stack.imgur.com/d6p5a.png) So the red in the second raster corresponds to a value of 0.47, rather than 0.66. How can I ensure that both rasters are using a consistent symbology?


QGIS copy and paste error: "no features could be successfully pasted"

What does this error message mean, and how can you get more info on what might be the cause? "no features could be successfully pasted" (or more generally, not all of the selected items could be successfully pasted) (I'm using QGIS 2.3 (build 422148c) on Vista Home Basic 32bit) Seems like it's probably a problem with the source data; what's a good way to track that down? If just modifying some of the source metadata would let the paste operation work, it would beat trying to reproduce the source data by hand in the target layer. Thanks UDPATE: looking at the metadata for successfully copied objects vs the object that dies, the one that won't copy has no firstX, firstY, lastX, lastY keys in the (Derived) section where the ones that paste successfully do have those keys with appropriate values.


Reference Coordinates System bounds

I have a catalog that contains different coordinates system definitions. I have a web interface where one should be able to see a given coordinate system extent in a google maps view. **My question is:** Given a CRS well known text, for example:               PROJCS["NAD_1983_CORS96_StatePlane_Missouri_East_FIPS_2401",GEOGCS["GCS_NAD_1983_CORS96",DATUM["D_NAD_1983_CORS96",SPHEROID["GRS_1980",6378137.0,298.257222101]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",250000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-90.5],PARAMETER["Scale_Factor",0.9999333333333333],PARAMETER["Latitude_Of_Origin",35.83333333333334],UNIT["Meter",1.0],AUTHORITY["ESRI",103397]]       How do I find out this CRS bounds in Lat long for example?


How to upload a csv file into esri map with coordinates and plot in an esri map

I have got a sample code to plot the points on an esri map using a csv file. But the csv file is maintained in a server, i'm unable to upload it from my local system.Please let me know how i can refer the csv file in my local system and plot the coordinates? Simple Map html, body, #map { height: 100%; width: 100%; margin: 0; padding: 0; } body { background-color: #FFF; overflow: hidden; font-family: "Trebuchet MS"; } var map, csv;                 require([         "esri/map",          "esri/layers/CSVLayer",         "esri/Color",         "esri/symbols/SimpleMarkerSymbol",         "esri/renderers/SimpleRenderer",         "esri/InfoTemplate",         "esri/urlUtils",         "dojo/domReady!"       ], function(         Map, CSVLayer, Color, SimpleMarkerSymbol, SimpleRenderer, InfoTemplate, urlUtils       ) {        urlUtils.addProxyRule({           proxyUrl: "/proxy",           urlPrefix: "earthquake.usgs.gov"         });         map = new Map("map", {           basemap: "gray",           center: [ -60, -10 ],           zoom: 4          });         csv = new CSVLayer("http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/2.5_week.csv", {           copyright: "USGS.gov"         });         var orangeRed = new Color([238, 69, 0, 0.5]); // hex is #ff4500         var marker = new SimpleMarkerSymbol("solid", 15, null, orangeRed);         var renderer = new SimpleRenderer(marker);         csv.setRenderer(renderer);         var template = new InfoTemplate("${type}", "${place}");         csv.setInfoTemplate(template);         map.addLayer(csv);       });     </script>


ArcGIS spatial join - WITHIN A DISTANCE including distance

I am applying a spatial join in ArcGIS between points (target features) and lines (join features). I want to have a 1-to-many join, so I use the match option 'within a distance'. So far so good. The annoying thing is that I need to have the distance between the point and the matched lines within the search radius. I do not find any solution for this. Is there someone who has a good tip for me that will do the trick? The final goal is that I need to join the points to the line that is nearby, but also has some other characteristics (equal value on some attributes, but also a timestamp that needs to be higher in 1 class than the other which I don't succeed in working with in arcGIS anyway). These kind of data preparation I do afterwards in other tooling. That's why I can't just take the one that is closest...


Print maps with a specific scale

I need to print a map (with Arcgis 10.0) that has an extension of 1200 kmq that formally has a scale of 1:25000. **Simply I need to print it with that specified scale (1:25000)** but do not know how. I've tried to looking on online guides, arcgis guides etc, and tried many options on print setup without success. Some suggestions? Thanks!


GetMap - WMS 1.1.0 vs 1.3.0

This works: http://mrdata.usgs.gov/services/sc?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=256&HEIGHT=256&FORMAT=image/png&BBOX=-83.4,32,-78.4,35.3&LAYERS=South_Carolina_Lithology&SRS=EPSG:4326&STYLES= This does not (blank image): http://mrdata.usgs.gov/services/sc?REQUEST=GetMap&SERVICE=WMS&VERSION=1.3.0&WIDTH=256&HEIGHT=256&FORMAT=image/png&BBOX=-83.4,32,-78.4,35.3&LAYERS=South_Carolina_Lithology&CRS=EPSG:4326&STYLES= Notice the 1.1.1 -> 1.3.0 and SRS->CRS are the only changes. Is this a problem with the service or is my second URL incorrect? I've observed the same issue with other Map Server services: Works: http://mesonet.agron.iastate.edu/cgi- bin/mapserv/mapserv?map=/mesonet/www/apps/iemwebsite/data/wms/goes/conus_ir.map&SERVICE=WMS&REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=256&HEIGHT=256&FORMAT=image/png&TRANSPARENT=TRUE&BBOX=-126,24,-66,50&LAYERS=conus_ir_4km_900913,conus_ir_4km&SRS=EPSG:4326&STYLES= Does not work (blank image): http://mesonet.agron.iastate.edu/cgi- bin/mapserv/mapserv?map=/mesonet/www/apps/iemwebsite/data/wms/goes/conus_ir.map&SERVICE=WMS&REQUEST=GetMap&SERVICE=WMS&VERSION=1.3.0&WIDTH=256&HEIGHT=256&FORMAT=image/png&TRANSPARENT=TRUE&BBOX=-126,24,-66,50&LAYERS=conus_ir_4km_900913,conus_ir_4km&CRS=EPSG:4326&STYLES= So I'm assuming it's an issue with my 1.3.0 URLs.


How to calculate a population weighted centroid using a raster and shape file in QGIS?

I am very new to QGIS so please help me with a step by step answer. I have a raster file with population count and a shape file based on a large population and shape file. I have successfully created the smaller raster and shape files for the region of interest. Now I just would like to find the population weighted centroid for this smaller region, and I don't know how (I know there is a related discussion, but it just provides the intuition and I don't know how to implement it in QGIS). I have used the vector--> analysis tool --> mean coordinate(s), but no matter what I choose in the weight field, I always end up with the same point, so something should be wrong. Also, do you know how I can find out to which map/variables the weight field values that are provided belong too?


Streaming polyline while adding records to related tables in ArcPad

I'm designing an ArcPad solution for our field staff; we collect point data and use lines to identify the amount of 'effort' (and to maintain accountability). While collecting a 'streaming polyline' (Add verticies continuously from GPS) as our field staff's "track" (daily effort) we need to also collect point data along the way. Every time you collect add a record to a point feature class in a related table in the poly-line streaming stops. This forces our staff to manually turn the polyline streaming back on for every record they collect. Human error is just about guaranteed over the course of editing 50 points in a day. I know that event handling is built into ArcPad through ArcPad Studio, but I haven't had any luck triggering the polyline streaming with the onOK event of related table's form. Any help putting together an event handler would be appreciated. The help files aren't nearly as useful as the Python sample code associated with ArcMap on the desktop. Here's a quick look at the direction I've been leaning. I'm not fully sure how to even compose a full even handling script for ArcPad. > From help files: 'gpsstream' => Add Vertices continuously from GPS > > **Form (onOk event):** > > **Application.ExecuteCommand("gpsstream")**


Disable button on User Form upon opening MXD?

I have a toolbar with two buttons that allow users to display an edit attribute window of a selected feature. I would like the buttons to be disabled until the user selects one feature. Current, I somewhat have this feature working. The button is enable whened opening the document and then it is disabled after the first time opening the window (I have it in the OnUpdate Event). How can I change this so that the button is disabled when the user opens the MXD and then is enable when only one feature is selected? I think my problem is just that i have it in the OnUpdate event?? _Using Visual Basic 2008 Express, ArcGIS 10_               Protected Overrides Sub OnUpdate()          Dim pFeatLyr As IFeatureLayer     pFeatLyr = GetLayerByTOC("AJ_RecommendedImprovementsLines")          'Enable Button     If GetFeatSelCount(pFeatLyr) = 1 Then         Me.Enabled = True     Else         Me.Enabled = False     End If     End Sub


Add feature layer to display with in a script tool for desktop mapping 'App'

**The point of this question is to find a way to programatically change the map extent based on user input. My method involves creating a Feature Layer & Selection, but if you have another (different) solution that gives the desired result, I'd love to hear it!** Now that I'm comfortable with arcpy and I've become aquainted with the mapping module I saw a niche. I can write start-to-finish desktop mapping applications to accomplish a specific task. This enables anyone in our office to run the 'app' without needing several years of using ArcMap to accomplish a repeatable task for a different area of interest (ie. zip-code, tax-parcel, county, etc.) I've written a few of these scripts and associated each of them with their own MXD to give the user a GUI. When they input some sort of attribute value (watershed number, land-parcel number, county, etc.) the script makes a feature layer of that polygon and uses the **zoom to selected feature** method to change the extent. The problem I'm having once I've finished debugging the 'app' through ArcMap's Python Window I create a **script tool** that gives the user an input box to enter in the required arguments for the program to run. For whatever reason, ArcMap defaults to **NOT** adding the feature layer to the map when it reaches the line of code where it is created. Therefore, my script cannot use the zoom to selected feature method to change the extent. The rest of the script runs along just fine, but the zoom extent is still at the state level as opposed to a sub-watershed level. **Code excerpt:**               try: # Clip wetlands layer to extent of user dictated parcel, calculate staticstics         newWetland = outWetlands + "HUC_" + userHucID # variable that stores clipped wetland output location & name         arcpy.MakeFeatureLayer_management(sheds, "currentShed", clipClause) # Create feature layer of HUC (from user input)         arcpy.SelectLayerByAttribute_management("currentShed", "NEW_SELECTION", clipClause) # Select current HUC         df.zoomToSelectedFeatures() # Zoom to extent of selected HUC         arcpy.RefreshActiveView()   # Refresh view of mxd before exporting to PNG              arcpy.Clip_analysis(wetlands, "currentShed", newWetland) # Clip dissolved wetlands layer to current HUC         arcpy.ApplySymbologyFromLayer_management(newWetland, layers + "WetlandSymbology.lyr") # Apply wetlands symbology         print "Finished creating wetland file for HUC #: " + userHucID + "."     except:         print arcpy.GetMessages()     finally: # delete the feature layer if it exists if an error is present or not         if arcpy.Exists("currentShed"):             arcpy.Delete_management("currentShed")      **Script run in the Python Window of ArcMap:** ![Script run correctly in Python window](http://i.stack.imgur.com/Cmw4I.png) **SAME script run as Script-tool in custom toolbox:** ![Same script run through Script tool in ArcMap](http://i.stack.imgur.com/kroxm.jpg) **Script tool Properties window:** This was suggested to me by an ESRI rep -- add a feature layer as a derived, output parameter, then use the SetParameter(index, featureLayer) to get the desired layer added to display. The parameter is derived (it isn't given by the user, but is derived by one of the user inputs), and set to output in an attempt to add it to the map. ![enter image description here](http://i.stack.imgur.com/fqOyL.png) **Attempted Fixes:**   * ArcMap Toolbar -> Geoprocessing -> Geoprocessing Options -> 'Add results of geoprocessing operations to the display'   * Add Feature Layer output parameter in script tool properties paired with arcpy.SetParameterAsText method   * `arcpy.mapping.AddLayer(df, layerPath)`   * `df.extent = layer.getExtent()`


Getting polygons of all countries and ISO-3166-2 subdivisons

In order to do reverse geocoding lookups to find a country (as ISO-3166-1) and the subdivision (as ISO-3166-2) for given coordinates I am looking for a way to get all polygons of all countries and their subdivisions. Reverse geocoding lookups with Google Maps or other services either do not always return the country and subdivision (Google Maps), or sometimes they are incorrect (geonames.org). As I understand it all countries and subdivisons are available in the openstreetmap data, but I do not know how to only retrieve the polygons - no map data, no points of interest or cities are necessary, only the outlines of all subdivisions with the given country and subdivision codes. Then I can check myself if a given point is within any given polygon, or near it. Does anyone know how to retrieve this data from the openstreetmap data, or is there any other source for this data?


Creating a graduated buffer in QGIS

I'm attempting to map cell phone towers and their range in QGIS. I'm wondering if it's possible to create buffers which change color intensity according to their distance from a central point. The buffer color is most intense at the center and gradually becomes lighter as one moves away from the center. I speculate that I must copy the range of each tower to the buffer layer attribute table and then select "Graduated" in the style menu of the buffer. Unfortunately, the buffer layer has only 1 row in its attribute table. Are there other solutions? Thank you.


create node ids with a multilinestring

I've got to make a route with my multilinestring table "routebus", but I can't create the node ids... maybe the fact that it's a multilinestring is the problem, but I really don't know how to solve it. I created "source" and "target" fields and tried with this query:               SELECT assign_vertex_id('routebus', 0.00001, 'the_geom', 'gid');      But it returns me an error:               ERROR: query string argument of EXECUTE is null     État SQL :22004     Contexte : PL/pgSQL function "assign_vertex_id" line 36 at EXECUTE statement      I'm not really used to PostGIS and pgrouting, maybe un must convert multilinestring to linestring? I have PostGreSQL 9.1.9 with PostGIS 2.0.1 installed Thanks in advance for your help


RFE raster images datum conflict

Im using ArcGIS 9.3. I've downloaded RFE images from FEWSNET. And im trying to load them on ArcMap, to clip them using Mozambique's shape. But as the RFE images related to Southern Africa come with unknown coordinate system, im having problems projecting RFE and Moz shape on the same map. I also tried to put them both at the same GCS which WGS_1984, and then use the same projection for both. It didnt work. Im a GIS begginer. Which is my mistake in this projecting and reprojecting issue???


access attribute values in openlayers rule

I have a webgis where i use openlayers and i'm trying to make a FOR loop to generate a series of rules for my POI layer. I have tried just like that: http://pastebin.com/CTuiWd4V My problem is that i cannot access attribute values of my layer in 3 params tahta i need: 'title', externalGraphic, and value. Anybody can help me do that? Thanks


Formula/ calculation for ESRI map coordinate conversion (meter to decimal degrees)

I'm new to ESRI mapping. I have a set of points in ESRI, with x, y, z coordinates, which I believe is in meters. I am now writing an Android program, and I do not want to depend on ESRI, thus I would like to get the coordinates and pin them on Google map. I have tried to use ESRI and export the coordinates to decimal degrees and pin them on Google map. But the position is not very accurate (varies from original position about 500m). So I was thinking if there any hard coding calculations that I could do to convert meters to decimal degrees? I'm looking for accuracy at around 1m.


How to construct geographies from WKTs

I am using a SQL Server 2012 database. I have noticed that geometries and geographies interpret WKTs differently. For instance, if I construct a _square_ polygon, clockwise:               DECLARE @geom Geometry=geometry::STGeomFromText('POLYGON((-30 -45, -30 45, 30 45, 30 -45, -30 -45))', 4326)     DECLARE @geog Geography=geography::STGeomFromText('POLYGON((-30 -45, -30 45, 30 45, 30 -45, -30 -45))', 4326)      The geometry will be interpreted (as intended) as the original square ( _inwards_ ): ![geometry](http://i.stack.imgur.com/sCtSX.png) But the geography will be interpreted as the complement of the square ( _outwards_ ): ![enter image description here](http://i.stack.imgur.com/TBS6r.png) Is this standard (and can you find a reference to why this is so)? And if so, how is it possible to construct a geography from a WKT?


Convert native box to geometry

I have an old table that contains bounding boxes of lat long coordinates in a "box" type. How do I convert them to PostGIS geometry ? I tried using `ST_Transform(ST_SetSRID(se.bound_box::box2d::geometry, 4326), 4326)` but it says I can't cast box to box2d or to geometry. Any help much appreciated


Weather interpolations QGIS

does any one know how good are the weather interpolations that QGIS carries out? Do you have any other suggestions or better methods to do them? Please let me know. Thanks in advance!


Domains can only be delete or modified by the owner?

Arcmap States that "When a new domain is created, the owner of that domain—that is, the user who created it—is recorded. Only the owner of an attribute domain can delete or modify it." So say for example a usercreates a domain, then this user leaves the organization. Would it be impossible to then edit or delete that domain?


How to export a vector layer to a new layer and take extent from canvas?

I want to create a new vector layer based on an existing one and the extent should be based on the current extent of the canvas. How do I do that? Edit: I am looking for a quick way to do that (a couple of clicks). I don't want to create any additional layers.


Cannot publish service with editable layer

We have several services published, up and running for our on-line viewers. However, we are trying to publish a service containing our bus stops, that can be brought up on a mobile device for editing in the field. We have a user set- up called "webedit" and the layer in the mxd is pointing to this datasource. When publishing, we check "Feature Access" and "Mobile Data" under the Capablilities. Start Service automatically is checked. Upon analyzing, only minor errros are reported - data extent, tags, summary, draws at all scales, things that shouldn't be deal breakers. It shows as published, but then gives the message that the service did not start and that it must be started thru server manager. When this is attempted, we get a rather non-descript "failure to start service". The last time we tried, we discovered we needed a GlobalID, and this has been added to the table. The error logs are no help either. All our other services publish fine. Any ideas?


Open/Free Area Code Shape Files for the US/Canada

I would like to map magicJack's areacodes and exchanges against known area codes and exchanges to create a coverage map, just to see what it would look like as compared with, say, a mobile phone coverage map. Having read this previous post: Shapefiles for U.S. Area Codes (NANP) I see the only available databases seem to cost more than I'm willing to pay. And the maxmind information is point data rather than polygon data. I'm curious if any new free/open resources have become available since the previous posting.


How to programmatically click on Feature or particular region without coordinates?

How I can programmatically click on feature using javascript library, lets say in world countries map how can I programmatically click on a particular country ( i don't want to use co-ordinate as my does not deal with them). Country Name comes form rest services. I will highlight the country through querytask i pass countryname in the country i get the feature object then i add symbol object to it and highlight it.               var queryTask = new esri.tasks.QueryTask("http://10.32.9.106:6080/arcgis/rest/services/KX_Mapping/World_countries_less_Antartica/MapServer/0");     var query = new esri.tasks.Query();     query.where="CNTRY_NAME IN ('Some')";         queryTask.execute(query);     dojo.connect(queryTask, "onComplete", function(featureSet) {                      try{                             console.log(" query complete");                             var symbol0 = new esri.symbol.SimpleFillSymbol().setColor(new dojo.Color([255, 0, 0, 0.9]));                             dojo.forEach(featureSet.features,function(feature){                                     //alert('feature'+feature);                                     var graphic = feature;                                     graphic.setSymbol(symbol0);                                     //alert("infoTemplate"+infoTemplate);                                     var infoTemplate = new esri.InfoTemplate("Alert", "ds");                                     graphic.setInfoTemplate(infoTemplate);                                     //alert("graphic"+graphic);                                     //alert("map.graphics"+map.graphics);                                     map.graphics.add(graphic);                             });                         }catch(e){                             alert("e"+e);                         }                     });      I have associated infotemplate object to graphic object , template will be shown when user click on that country , how can i programitically make it clickable.


How to enable OSM map in Garmin?

I've installed two OSM maps, but I cannot use them in Garmin. See the window of Utilities / Manage Map Products: ![enter image description here](http://i.stack.imgur.com/bmyUJ.png) The maps are not lockable, but I cannot use them in Garmin... What shall I do to be able to upload them to my GPS? Thanks a lot!


How to get the Reconcile Versions geoprocessing tool published as an arcgis server 10.1 service to work with a new version

After publishing the Reconcile Versions GP tool to ArcGis server 10.1, it can be successfully invoked via REST but only on versions existing at the time the service was published. If a new version is created the service fails. The error is: > ERROR 000622: Failed to execute (ReconcileVersions). Parameters are not > valid.\nERROR 000800: The value is not a member of...(list of version names) Is there some way to publish this tool so it can reconcile versions that are created dynamically?


shapefiles for global border crossings

I am trying to find a shapefile or set of shapefiles that contain global border crossings. Basically, what are the points of transit between one country and another. Does anyone know if this data is available? I am particularly interested in crossings in Sub Saharan Africa, like Zambia, Zimbabwe, Malawi, etc., and around Syria. Any help would be appreciated. I have already checked the usual sources of shapefiles and no luck.


Automatically update feature class based on another feature class in same geodatabase

I work at headquarters and there are 3 regions. Each region is responsible for their data and headquarters is responsible for merging the data and creating a national coverage. All regions and headquarters have the same fields in their feature classes. I am using ArcGIS 10.1. The data is currently stored as follows: there’s one SDE geodatabase, each region has a Feature Dataset with their data in it. Headquarters also has a Feature Dataset with national data – which is just basically a merge of the regional datasets. What I want is an automatic or even semi-automatic way of updating a national feature class when the related regional feature class has been updated. I originally wanted to have a geodatabase for each region and then create a parent child relationship but the IT people will not allow it. We are allowed only one geodatabase on the network for this project. I made a test file geodatabase locally and I have tried to create a Relationship Class with one region and headquarters. I put the region as the origin and national data as the destination. I made it a 1 to 1 and composite relationship. It was created successfully, but then when I edited the regional data (I added a new polygon, moved a polygon, deleted a polygon and changed the name of a polygon) the changes were not reflected in the related national feature class. I want to know if the Relationship Class the best route to take for this project (assuming I can get it to work) or should I get my hands dirty with Python and use an update cursor? Or is there some other solution that I haven’t considered? edit: The database is a SQL Server Enterprise Database and Headquarters has all privileges, but the regions are only able to edit their own. There are four feature classes per region, three of which will be edited. They are not currently versioned. Right now the process of updating is tedious – they send us the file and we update the national. They do all have GUID columns. Everything is running through shared services on Citrix, so there is a login associated with each user.


Saving edits slowing down (QGIS 2.01)

QGIS 2.01 on Windows 8 I have a polygon layer which I edit in QGIS 2.01. Editing (cutting, deleting, editing new polygons with attributes) works fine. I am saving the changes after every edit or so while in edit session. Then after editing away for some time (10 Min) and saving 4-5 edits the saving process becomes unbearably slow and it takes between 1 and 7 (!) minutes to save the changes. Mouse cursor is going crazy, CPU and ram are maxing out. Then after the edits are finally saved, ending the edit session again takes several minutes. I tried the dataset with SQLite and shp, both delivered the same experience. Any clues why this might be the case? Thanks for your help.


How to create 3D water depth with ArcScene?

I was trying to visualize flood depth in 3D using ArcScene. What I had for this purposes are:   1. high-resolution DTM of the valley    2. orthophoto and   3. Raster with flood depth information. I have draped the orthophoto over the DTM and it looks like as follows: ![enter image description here](http://i.stack.imgur.com/i0TFc.png) Then I draped orthophoto over it: ![enter image description here](http://i.stack.imgur.com/7oOB6.png) Finally I overlayed flood map on top of orthophoto: ![enter image description here](http://i.stack.imgur.com/FTalC.png) My question is , is there any way to visualize flood water in 3D with height. it looks like Flood depth raster only touches the base of the DTM. But I need to incorporate DTM + raster height in Flood depth map . How can I do it ?


GDAL and Geospatial PDF on Windows

GDAL 1.8 now supports reading GeospatialPDF, see pdf format description page. Using it depends on the poppler pdf library. What is the smoothest route to getting gdal and geospatial pdf working on Windows? UPDATE: I mean getting the gdal _utilities_ , the end user programs not the just the programming libraries.


Converting Landsat8 DN to TOA reflectance for use in envi

I am used to working in envi, however my current version does not support Landsat8. I downloaded GRASS for the express purpose of converting Landsat8 DN to TOA reflectance for use/analysis in envi. I have managed to do the conversion fine using the tutorial provided (http://courses.neteler.org/processing-landsat8-data-in-grass- gis-7/#Unpacking_the_downloaded_Landsat_8_dataset), however once I try to export that to a format usable by envi, I get stuck. I have tried " **r.out.tiff** ": However get this warning: "WARNING: Raster map > is a floating point map. Fractional values will be rounded to integer" When I load it in envi it is clear that the image quality has decreased and it is no longer suitable for my analyses. When I try " **r.out.gdal** ": I get the following error message: "ERROR 6: SetColorTable() only supported for Byte or UInt16 bands in TIFF format." And when I try to open it in envi, I get this message: "Cannot open in envi: unsupported number of bits per pixel" Can anyone help me please?


Create line between polygon and nearest raster cell

I need to create a line between polygons (centroid) and the nearest cell of a raster dataset. The polygon and raster do not intersect. Each polygon has a UID. One cell can be linked to many polygons, but the polygon can only be linked to one cell. To start, I'm converting the raster to point. From there, I think a Spatial Join needs to be performed using "CLOSEST" as the match option. If I can get the raster cell point to have the polygon UID, I can then use Points to Line with the UID field as the "Line Field" parameter to create an individual line between the two points to connect the polygons to the nearest raster cell. I tested this on a small area and sample, but it was taking a long time to run each step. In the end, this needs to be performed for hundreds of polygons at a time. Can anyone tell me if I'm on the right track or offer any suggestions to make this work? Some searching has indicated using Near analysis and creating a line from the xy coordinates could be an option as well. Whatever is most efficient. Thanks! EDIT: Making a grid with only values along the boundary would make the raster to point processing faster, as described here. I'm still not sure if the rest of the process is going to work correctly.


Geodatabase Connection to Oracle Active Data Guard Standby

Thank you in advance for any help you can provide. **ENVIRONMENT** Database Server:   * Oracle 11.2.0.2.0 Single-Instance Database on Windows Server 2003 R2   * Enterprise 64-bit Oracle Active Data Guard for Oracle Database 11g R2   * ArcSDE for Oracle 11g 9.3.1 SP2 using SDELOB Client Machine:   * Oracle Client 11.2.0.1.0 on Windows 7 Enterprise   * ArcGIS Desktop 9.3.1 SP2 on Windows 7 Enterprise   * ArcGIS Desktop 9.3.1 SP2 QIP Patch   * ArcGIS Desktop 9.3.1 SP2 Geodatabase Patch   * ArcGIS Desktop 9.3.1 SP2 Geometric Network Patch **BACKGROUND** I have successfully created two standby databases from my primary Oracle database; one is a physical standby (with realtime-SQL enabled) and the other is a logical standby. When attempting to connect to either of the standby databases using direct connect in ArcCatalog, I receive the following error: Error: Operation Failed (-1) It then occurs to me that both standby databases are running in read-only mode, which is expected when creating standby databases via Oracle Active Data Guard. After some more research, I find that it is possible to modify a standby database such that it can run in read-write mode. After modifying the standby to run in read-write mode, I am then able to make edits to the standby. Afterward, however, I was unable to resume the application of redo logs for the standby database which essentially broke the connection between my standby and my primary. This was evident after receiving a variety of Oracle errors (e.g., ORA-01665 and ORA-01153) when following the Oracle documentation for how to switch from the standby back to the primary. In essence, I wasn't able to re-link the standby and primary databases ever again such that redo logs were applied correctly from the primary to the standby. The good news is that I _can_ connect to either the logical or physical standby if I perform a Switchover within OEM 12c R3 such that the primary and standby databases swap roles. Therefore, I think it has something to do with the read-only status of the database whereby Data Guard is enabled. After some discussion with a contact at Esri, part of the solution might reside in the SDE.SERVER_CONFIG table, specifically with the READONLY parameter. Setting the CHAR field to TRUE and the NUM field to 1 would set the geodatabase to read-only mode (Esri's method of read only). However, I can't change this value on the standby because it's in read-only mode according to the Oracle software. I found out that making a geodatabase connection actually performs edits at login. There is an Oracle package that executes a function or two which performs inserts and object creations within the database. Setting the geodatabase to read-only mode per the method above may be the way to change this behavior but I'm still waiting for answers at the moment. Lastly, I believe there are a list of exclusions that are needed when setting up the Active Data Guard replication for _logical_ standby databases. I'm yet to find those, though. **QUESTION** Has anyone used ArcSDE in conjunction with Oracle Active Data Guard? If so, how am I able to make a geodatabase connection to the standby? Any insight would be greatly appreciated. I am trying to determine the high-level proper workflow for creating a standby database and subsequently configuring the standby to receive archived redo data from the primary database (using either Redo Apply, Real-Time Apply, or SQL Apply).


Read esri shape point data and spline interpolation using python shell scripts?

I am quite new in python scripting. I am a dedicated user of arcgis but this time I have to work without arcgis. I have a point shapefile with 10 different attribute fields of different peat layer with ordered sequence. I have to make spline interpolation with each specific layer and also have to use polygon mask to limit the interpolation area. I am wondering if anyone could help me guide a workflow so that I can do it without the help of arcgis?


How to compute a line intersection point in a street layer in postgis 1.4?

I have a street layer downloaded from osm. I need to calculated intersection point as we do in qgis from vector menu -> Analysis tool -> Line intersections. I am new to postgis/postgres. any how i managed to download and install it spending whole day on ubuntu machine.using `shp2psql-gui` i imported data into pgadmin3. i know how to do in QGIS. but tell me how to do same in postgis.i have heard some st_intersects etc. but it cant help. i want to return something like this Below are snapshot for more clearer picture of my issue. Blue indicate street layer. ![enter image description here](http://i.stack.imgur.com/RMk8l.png)               name_1 | name_2 | laitude | longitude     xyz st | abc st | #value| #value     lmn st | pqr st | #value| #value     xyz st | pqr st | #value| #value     pqr st | abc st | #value| #value     lmn st | xyz st | #value| #value     lmn st | abc st | #value| #value


SLD to Esri lyr file?

Does anybody know if there's a sw/extension to convert an SLD to Esri. lyr format, or to import the SLD directly?


Node rating like in Google Places?

Is there any tool or node/way tag in openstreetmap to obtain a POI rate as with the Google Places service ?(here nodes/places have a label/tag with the rating. e.g. `<rating>3.2</rating>`) Thanks in advance!


How to determine the Geoid model used by GPS receiver?

I have the following NMEA output by Holux M-241 GPS receiver:               $GPGGA,144014.000,2227.0987,N,11410.1382,E,2,6,1.67,32.6,M,-1.3,M,0000,0000*7B      I know that WGS84 height is higher than geoid height 1.3 meter. But how can I know that which geoid model it is using? Also, is it a database stored in the GPS chip for geoid height and WGS84 height conversion?


How to add offsets to the route?

**Edited:** ![sample](http://i.stack.imgur.com/7ucef.jpg) I want to ilustrate my question. Suppose that you're in "Point A" and want to go to "Point B". This points wouldn't be in "at_2po_4pgr" table cause aren't source/targets nodes. Then, I would search for the nearest node for points A and B (green points). After this, I might perform a shortest_path call using green points ids and I would obtain "orange" path. But to obtain the real path cost (distance) in first case I would have to substract "offsetA" and in second case add de "offset B". To calculate distance between red-points and green-points, I run the following query: `SELECT * FROM st_distance( ST_GeomFromText('POINT(-3.6963314 42.3498066)',4326), ST_GeomFromText('POINT(-3.6954276 42.3479634)',4326))`. How I would know when add or substract the offset? Sorry for my english!


V.kernel not working correctly in grass-6.4.2

I am using grass-6.4.2 for generation of heat maps of crime data. For testing purpose, I created a vector layer from my places shapefile which is a point data.The places shapefile contains more than 3000 data.I used **v.kernel** command for generation of raster map as follows:               g.region rows=20 cols=20     v.kernel input=Places@PERMANENT output=raster1 stddeviation=0.001      But the output was a rectangle. I increased the `stddeviation` value step by step to 10000. The output has `Maximum value in output: 1.591528e-11.` but the raster image is completely wrong. Please help me in solving this issue. * * * I checked with rows=600 and columns=600 with a standard deviation of 1000. Here is the output I got:               (Thu Nov 15 11:05:14 2012) Command finished (0 sec)                                  (Thu Nov 15 11:06:05 2012)                                                           v.kernel input=Places@PERMANENT output=raster3 stddeviation=10000                    STDDEV: 10000.000000     RES: 1324.680000    ROWS: 600   COLS: 600          Writing output raster map using smooth parameter=10000.000000.          Normalising factor=648263501.877776.     Maximum value in output: 1.589441e-09.     (Thu Nov 15 11:06:07 2012) Command finished (2 sec)      All I get is several rings with different colors radiating from the center. Thanks in advance.


Is there a way to use image sprite for different marker icons?

I just made the switch from Google Maps V3 to OpenLayers. I realise that OpenLayers API uses a lot of inline styling. If an image file consisting of several images can be used, it would cut down server request. Has anyone implemented this on marker icons of varying sizes?


What is the CRS for France

Has anyone any idea what the CRS is for France? I am new to QGIS (moving over from using Arcgis) and trying to find out basics. I have found a huge list beginning NTF (Paris) but wonder which one to apply.


How to take 2 points from One featureClass, create a line between those points, and add the line to a new featureClass (aka Shape File)?

I'm a total noob/beginner in ArcObjects. I'm coding in C#. I want to extract 2 points from a given featureClass, create a straight line between those 2 points, create a new feature class and add those points to the new featureClass. The following is code (I have taken a lot of code from internet), but I am facing problems.               some_function()     {             IWorkspaceFactory workspaceFactory = new FileGDBWorkspaceFactory();             IWorkspace workspace = workspaceFactory.OpenFromFile(@"myGDB1.gdb", 0);                  IFeatureWorkspace featureWorkspace = workspace as IFeatureWorkspace;             IFeatureClass fc_tenActors = featureWorkspace.OpenFeatureClass("ten_points");                            ISpatialReference lineFeatureSpatialReference = GetSpatialReference(fc_tenActors);             IFeatureClass fc_line1 = IFeatureWorkspace__CreateFeatureClass(featureWorkspace, "Line1", lineFeatureSpatialReference);             fc_line1 = featureWorkspace.OpenFeatureClass("Line1");             IFeatureCursor featureCursorInsert = fc_line1.Insert(true);             IFeatureBuffer featureBufferInsert = fc_line1.CreateFeatureBuffer();                  IFeature pFeature1 = fc_tenActors.GetFeature(3);             IGeometry pFirstPointShape = pFeature1.Shape;             IPoint pFirstPoint = pFirstPointShape as IPoint;                  IFeature pFeature2 = fc_tenActors.GetFeature(4);             IGeometry pSecondPointShape = pFeature2.Shape;             IPoint pSecondPoint = pSecondPointShape as IPoint;            //************* PROBLEM HERE************************************             IFeature pLine = CreateSegment(pFirstPoint, pSecondPoint);        //************* PROBLEM HERE**************************************       //  This is problem. pLine is empty after this statement.                  featureBufferInsert.Shape = pLine.Shape;                         AddFields(featureBufferInsert, pLine);             featureCursorInsert.InsertFeature(featureBufferInsert);             featureCursorInsert.Flush();          }               public static IFeature CreateSegment(IPoint pFrom, IPoint pTo)         {             Line line = new LineClass();             line.PutCoords(pFrom,pTo);             return line as IFeature;         }          private static void AddFields(IFeatureBuffer featureBuffer, IFeature feature)         {             // Copy the attributes of the orig feature the new feature             IRowBuffer rowBuffer = (IRowBuffer)featureBuffer;             IFields fieldsNew = rowBuffer.Fields;                  IFields fields = feature.Fields;             for (int i = 0; i <= fields.FieldCount - 1; i++)             {                 IField field = fields.get_Field(i);                 if ((field.Type != esriFieldType.esriFieldTypeGeometry) &&                     (field.Type != esriFieldType.esriFieldTypeOID))                 {                     int intFieldIndex = fieldsNew.FindField(field.Name);                     if (intFieldIndex != -1)                     {                         featureBuffer.set_Value(intFieldIndex, feature.get_Value(i));                     }                 }             }         }


XML not getting convert into list of Feature Objects

I'm getting a following XML response: `<wfs:FeatureCollection xmlns="http://www.opengis.net/wfs" xmlns:wfs="http://www.opengis.net/wfs" xmlns:Alexandria="http://www.opengeo.org/alexandria" xmlns:gml="http://www.opengis.net/gml" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opengeo.org/alexandria http://localhost:8080/geoserver/wfs?service=WFS&version=1.0.0&request=DescribeFeatureType&typeName=Alexandria%3ALink http://www.opengis.net/wfs http://localhost:8080/geoserver/schemas/wfs/1.0.0/WFS-basic.xsd"> <gml:boundedBy> <gml:null>unknown</gml:null> </gml:boundedBy> <gml:featureMember> <Alexandria:Link fid="Link.3606"> <Alexandria:link>10011</Alexandria:link> <Alexandria:street>MetroRail</Alexandria:street> <Alexandria:anode>7809</Alexandria:anode> <Alexandria:bnode>7810</Alexandria:bnode> <Alexandria:length>5900.0</Alexandria:length> <Alexandria:setback_a>7.5</Alexandria:setback_a> <Alexandria:setback_b>7.5</Alexandria:setback_b> <Alexandria:bearing_a>258</Alexandria:bearing_a> <Alexandria:bearing_b>264</Alexandria:bearing_b> <Alexandria:type>HEAVYRAIL</Alexandria:type> <Alexandria:lanes_ab>1</Alexandria:lanes_ab> <Alexandria:left_ab>0</Alexandria:left_ab> <Alexandria:right_ab>0</Alexandria:right_ab> <Alexandria:speed_ab>24.0</Alexandria:speed_ab> <Alexandria:fspd_ab>15.0</Alexandria:fspd_ab> <Alexandria:cap_ab>800</Alexandria:cap_ab> <Alexandria:lanes_ba>1</Alexandria:lanes_ba> <Alexandria:left_ba>0</Alexandria:left_ba> <Alexandria:right_ba>0</Alexandria:right_ba> <Alexandria:speed_ba>24.0</Alexandria:speed_ba> <Alexandria:fspd_ba>15.0</Alexandria:fspd_ba> <Alexandria:cap_ba>800</Alexandria:cap_ba> <Alexandria:use>RAIL</Alexandria:use> <Alexandria:notes>Network Link</Alexandria:notes> <Alexandria:the_geom> <gml:MultiLineString srsName="http://www.opengis.net/gml/srs/epsg.xml#26918"> <gml:lineStringMember> <gml:LineString> <gml:coordinates xmlns:gml="http://www.opengis.net/gml" decimal="." cs="," ts=" "> 320695.41213026,4297152.0969028 320640.19318712,4297139.92142997 320587.60391463,4297132.73849488 320507.99922226,4297125.6462426 320372.01896506,4297122.04868058 320139.61381536,4297133.2460428 319570.57549324,4297180.04088008 319077.50062411,4297238.93844794 318769.48314967,4297273.2403574 318384.07201306,4297311.44152552 318358.66079594,4297313.94256447 318010.3407805,4297343.94430273 317699.46222885,4297367.34752366 317497.16184099,4297366.53956364 317208.71190984,4297321.60207638 316919.31081203,4297234.0455083 316803.6568586,4297185.98240055 316572.93697881,4297064.62138347 316385.3476619,4296950.17015898 316099.77576633,4296847.2680627 315736.80626258,4296749.50396585 315523.91602008,4296708.32610939 315280.39092313,4296675.23725991 314961.76338186,4296641.82134139 </gml:coordinates> </gml:LineString> </gml:lineStringMember> <gml:lineStringMember> <gml:LineString> <gml:coordinates xmlns:gml="http://www.opengis.net/gml" decimal="." cs="," ts=" "> 314962.12893922,4296638.34050277 315280.80907687,4296671.76274009 315524.48397992,4296704.87389061 315737.59373742,4296746.09603415 316100.82423367,4296843.9319373 316386.8523381,4296947.02984102 316574.66302119,4297061.57861653 316805.1431414,4297182.81759945 316920.48918797,4297230.7544917 317209.48809016,4297318.19792362 317497.43815901,4297363.06043636 317699.33777115,4297363.85247634 318010.0592195,4297340.45569728 318358.33920406,4297310.45743553 318383.72798694,4297307.95847448 318769.11685033,4297269.7596426 319077.09937589,4297235.46155206 319570.22450676,4297176.55911992 320139.38618464,4297129.7539572 320371.98103494,4297118.55131942 320508.20077774,4297122.1537574 320587.99608537,4297129.26150512 320640.80681288,4297136.47857003 320696.1649725,4297148.67951847 </gml:coordinates> </gml:LineString> </gml:lineStringMember> </gml:MultiLineString> </Alexandria:the_geom> </Alexandria:Link> </gml:featureMember> </wfs:FeatureCollection>` This response is stored in a variable named `response`. I try to convert it into list of feature objects by the following code:               var features = new OpenLayers.Format.GML().read(response);      I get an empty array ([]) when I print features. Can anybody point me out what I'm doing wrong?


Postgis extension is not detected although it's installed

I have a database with postgis extension installed. i can verify it by running \x then \dx. The postgis and postgis_topology is available. But, if i run `SELECT PostGIS_Version();`, it says ERROR: function postgis_version() does not exist. The question is, \x and \dx shows that the database have postgis extension installed. But when i want to verify it with `SELECT PostGIS_Version();`, it says ERROR: function postgis_version() does not exist. HINT: No function matches the given name and argument types. You might need to add explicit type casts. And if i try to `CREATE EXTENSION postgis;` it says. ERROR: extension "postgis" already exists. **SOLVED ! Turns out, the schema is not public.** So this is what i did. I just `ALTER EXTENSION postgis SET SCHEMA public`.


Tilemill misses parts of motorways from PBF

I have a problem with importing data from PBF format. See the pictures below. This happens at all zoom levels, which is really annoying. `osm2pgsql -d gis -U postgres --style openstreetmap-carto.style --hstore -C 2048 error-highway-only.pbf` ![Tilmill osm2pgsql PBF error](http://i.stack.imgur.com/dxP8e.png) The same import command with osm file is ok: ![Tilemill import ok](http://i.stack.imgur.com/0ZpuL.png) Here is what i used:   * postgresql 9.3 x64-win   * osm2pgsql SVN version af61cae663 (64bit id space) from February 6, 2013   * OSM and PBF files + tilemill test-project Please   * do you know how to correctly import PBF on Win_x64?   * possibly where to get newer osm2pgsql?   * possibly is there another option then cygwin binary? (i prefer mingw to cygwin) Any help much appreciated!


What kind of hardware configuration is needed for fast map services?

I have been trying to figure out the best way to have fast map services. So far i have done lot of changes on the process side like scale rendering, analysis, projections, SDE data layer indexing, seperating map services etc. I have found some improvement. I am at the point where I need to figure out the best hardware configuration that will provide fast map services. I have gone through some documentation from ESRI and it seems lot of information but hard to get develop clear understanding. Being a developer, I am looking for some solid/simple ideas on what i should be asking my Server team. This is the last option that i would like to explore. Appreciate any feedback. Thanks Jay


How to Create Evenly Spaced Nodes/Lines or Set a Spacing Rule in Arc 10

I have written a Python script for ArcMap 10 that uses the x/y coords from a shapefile to create perpendicular transects to the existing line. Since these shapefiles are actually rivers the lines are very curved. In order to accurately represent the river's shape there are more points in the curves. My problem is that the program I created takes all of these points to create multiple transects and in the curves it looks like a horrible mess because there are so many points. Is there any way to create some kind of spacing rule where my program chooses evenly spaced nodes so I can avoid this messy overlap? Any suggestions will be greatly appreciated. Nick Wissler Naval Research Lab


ArcObjects: IMapEvents.FeatureClassChanged doesn't fire if the layer's previous data source was invalid

Is there any other event besides `IMapEvents.FeatureClassChanged` that will be fired when a layer's data source changes? `FeatureClassChanged` doesn't seem to fire if the layer's previous data source was invalid (red exclamation mark next to the layer in the TOC).


arcpy: check for same record in cell above and below

After using the find duplicates in arcmap 10, I want to check if the feat sequence ("find duplicates" marks all records with the same attributes with the same number [in "feat_seq"] and creates a ROWID_ that has unique numbers for each record) is the same in the cell above and below and record and if it is the same then mark the duplicate/triplicate etc as "1", if not mark with 0. > The logic we used in excel is =IF(OR(C1=C2,C3=C2),1,0) > > If c2 = c1 or c2 =c3, give the cell a value of 1, if not, give the cell a > value of 0. Used to identify duplicate values that are in order. If the cell > above or below is the same as the cell in question, give the cell a value of > 1. If not, give the cell a value of 0. The code I started to write was               import arcpy     rows = arcpy.UpdateCursor("TestDuplicateID")          for row in rows:         rowCur=row         rowPost= row.next()         rowPre= # how can we get this?                   if rowCur.getValue("FEAT_SEQ")==row.getValue("FEAT_SEQ"):             rowCur.setValue("Dups", "1")         elif rowCur.getValue("FEAT_SEQ")==rowPre.getValue("FEAT_SEQ"):             rowCur.setValue("Dups", "1")         else:             rowCur.setValue("Dups","0")      I can't seem to find a way to retain the PRE record and get the following error "Runtime error : unsupported operand type(s) for -: 'Row' and 'int'". Thanks for your help


GeoDjango 'NoneType' error when using 'distance' function

I have a site that's working on our staging server but after copying it to the live server I am getting the following error when trying to perform a distance() call (code cut down to minimum)               >>> Buddy.objects.all().distance(pnt[0].geom, field_name='postalcode__geom')                                                                                Traceback (most recent call last):       File "<console>", line 1, in <module>       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/models/query.py", line 100, in distance         return self._distance_attribute('distance', geom, **kwargs)       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/models/query.py", line 582, in _distance_attribute         geodetic = geo_field.geodetic(connection)       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/models/fields.py", line 131, in geodetic         return self.units_name(connection) in self.geodetic_units       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/models/fields.py", line 122, in units_name         self._get_srid_info(connection)       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/models/fields.py", line 108, in _get_srid_info         self._units, self._units_name, self._spheroid = get_srid_info(self.srid, connection)       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/models/fields.py", line 35, in get_srid_info         units, units_name = sr.units       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/backends/base.py", line 281, in units         return (self.linear_units, self.linear_name)       File "/home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/backends/base.py", line 253, in linear_units         return m.group('unit')     AttributeError: 'NoneType' object has no attribute 'group'          >>> pnt[0].geom     <Point object at 0x1fb0370>      I've been unable to find any information elsewhere this error. Any help as to what might be causing this would be very welcome. **EDIT** Not having a clue what I'm doing, I've come up with possibly the best patch in the world /s               --- /home/buddyup/base.py       2012-01-18 22:17:04.000000000 -0500     +++ /home/buddyup/sites/buddyup/lib/python2.6/site-packages/django/contrib/gis/db/backends/base.py      2012-01-18 22:16:09.000000000 -0500     @@ -239,7 +239,8 @@                  return None              else:                  m = self.units_regex.match(self.wkt)     -            return m.group('unit_name')     +            return 'meter'     +            #return m.group('unit_name')               @property          def linear_units(self):     @@ -250,7 +251,8 @@                  return None              else:                  m = self.units_regex.match(self.wkt)     -            return m.group('unit')     +            return 'm'     +            #return m.group('unit')               @property          def angular_name(self):      I have no idea why it is unable to find the units or the units name, but for now that works for me. I would love to hear what the actual problem could be and find a valid solution. **EDIT 2**               yum install gdal      After talking to pizzaparty in the #django IRC channel he pointed out that installed gdal should stop Django trying to get the units from a Point object that doesn't have any. That seems to be a much better solution.


Convert absolute file path to raster databaset

I wrote a simple python script that outputs an absolute path as string to a GeoTiff file. So this file can be treated as Raster. In a Model, the GeoTiff file is to be the input raster of a CopyRaster arctool procedure. I dragged the python script in the Model and realised CopyRaster only accepts Raster Dataset as input but not the string. How can I make the python script work the CopyRaster tool?


Is the TIN created out of several cross sections different from merging the TINs created out of each set of two cross sections?

I have a river with cross sections that have the water surface elevation values. I am trying to create TIN from the water surface values and then compare it with the topo (to see the flooded areas). I wonder what would be the difference between the TIN created out of several cross sections is different from merging the TINs created out of each set of two cross sections? Does the TIN creation process includes any sort of generalization/ approximation/ getting average when it comes to several features or it is dependent on the adjacent features only? My tests on the river shows no distinct difference between the resulting floodplain but I am not quite sure it is the same everywhere. Any thought? ![enter image description here](http://i.stack.imgur.com/9V7EO.jpg)


OpenLayers Vector polygon and Jquery Droppable

How can I use Jquery Droppable to drag and drop an Icon over an openlayers polygon vector and select the polygon while over on hover? I have managed create a create a popup when over a div element, but i cant figure out how to do the same for a polygon inside the "map" div. Hope that makes sense. Here is a link to show the concept: Update: Here is a bit of code to show specifically the bit of code I am struggling with. I can currently select a polygon by clicking...but want to select by dropping an icon on the polygon.               $(function() {          $( "#cow" ).draggable({ revert: true});     $( "#map" ).droppable({       drop: function( event, ui ) {              **\\How do I select a polygon on drop here?**         alert( "Dropped!" );       }     });


Is there a way to export data with coordinates from QGIS to a csv file

I have saved waypoints from my Garmin as gpx and have successfully imported them into QGIS. Is there a way to now export the layers into a csv file with coordinates? I've tried the export to csv but that does not give me the coordinates.


Insert cursor raises exception on geodatabase

world, I'm having trouble to insert a line geometry into a personal geodatabase (using `Python/ArcGIS 9.3.1`). Everything works fine if the target feature is a shapefile. My guess is that calling: `traj.shape = lineArray` is causing the exception:                File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 570,       in __setattr__ raise AttributeError("Property '%s.%s' can not be set." %      (self._username_, attr))AttributeError: Property '<unknown>.shape' can not be set.      However, lineArray holds the coordinates of the vertexes. To populate a new row I call:               newTraj = rowInserter.newRow()      newTraj.shape = lineArray     rowInserter.insertRow(newTraj)     lineArray.RemoveAll()     del rowInserter      Is there maybe someone with some experience on this topic? Thanks for your help in advance, Lars


Avoiding Legends too large to display in ArcGIS message from ArcGIS for Server WMS service?

I have created a WMS on ArcGIS for Server 10.2 with a polygon layer which contains a unique value renderer with 4 categories. The resulting legend item can be called via service call, which responds with an image of 22 width and 64 height in pixels, this legend item is not displayed in the table of contents. (other layers symbolized with a single symbol of 12x12 pixels have a legend in ToC). When I open the properties of the WMS Server and click on the layer which has no legend in Table of Contents (ToC), I can see: > Legend Information: Available(Legends too large to display in ArcGIS) A little googling results in this page: Using WMS service layers It is documented that... > ...when the image received for a layer in a WMS service exceeds this limit, > no legend is displayed for the layer My question: Is there a way to alter the limits of the legend item shown in ArcMap?


Which Writer do I need for PDF Documents in FME 2014?

I have successfully used the ImageFetcher transformer to download many images from a URL by using a JPG writer. Now I want to do this with PDF Documents, but have the problem that the Adobe 3D PDF writer and Adobe Geospatial PDF don´t write the outputs to a file. Here is the log. How can I use the HTTPfetcher to download pdf documents?                   f_39(CreationFactory): Created 1 features     f_40(TeeFactory): Cloned 1 input feature(s) into 0 output feature(s)     MULTI_WRITER: multi_writer_id `1': Started outputting features     Trying to find a DYNAMIC plugin for writer named `PDF2D'     Loaded module 'PDF2D' from file 'C:\Program Files (x86)\FME\plugins/pdf/pdf.dll'     FME API version of module 'PDF2D' matches current internal version (3.7 20140327)     FME Configuration: No destination coordinate system set     FME API version of module 'PDF2D' matches current internal version (3.7 20140327)     Writer `PDF2D_1' of type `PDF2D' using group definition keyword `PDF2D_1_DEF'     FME API version of module 'PDF2D' matches current internal version (3.7 20140327)     Could not open output file for writing.  Please verify that the file is not open in other applications or that the file is not read-only     A fatal error has occurred. Check the logfile above for details     =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-     Feature output statistics for `PDF2D' writer using keyword `PDF2D_1':     =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-                    Features Written     =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-     ==============================================================================     Total Features Written                                                       0     =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-     A fatal error has occurred. Check the logfile above for details     A fatal error has occurred. Check the logfile above for details     FME Session Duration: 51.7 seconds. (CPU: 3.3s user, 0.3s system)     END - ProcessID: 8464, peak process memory usage: 103668 kB, current process memory usage: 103252 kB          A fatal error has occurred. Check the logfile above for details     Program Terminating          Translation FAILED.


Best method to georeference oblique photographs?

I have a series of oblique photos taken from an airplane of oyster beds that need to be mapped. Does anyone have any tips on georeferencing oblique images? I have access to ArcGIS and ENVI.


Way to Ensure that the Image Centroid is Within Image Bounds

My application uses the ArcGIS Silverlight API to select polygons from a map layer. It uses the Geometry.Extent.GetCenter() method to get the centroid of the shape and add a thumbtack image at those coordinates. The problem I'm having is that for some shapes (crescents, for example), the centroid will actually fall outside the bounds of the shape. In this case, the thumbtack will appear outside of the shape. Is there any way that I can ensure that the coordinates I choose are actually inside of the polygon?


How to format dynamic text element in Data Driven Pages

Is there a way to format the Name element generated as dynamic text from Data Driven Pages. This element serves as my title and it is too long and needs to be wrapped onto another line.


How WiFi can tell my exact location?

There is no GPS installed in computer PC/laptops. Please let me know how WiFi can show my exact location.


How can I centralize QGIS connections for multiple QGIS installations

I have multiple computers with QGIS installed on them. I regularly use the same WMS / WFS services. Now I have to connect to these services for each QGIS installation separately. It would be great if there was a way to place the configuration for connections in the QGIS browser on a centralised locations (such as a NAS). That way I could access the same connections from every QGIS installation without having to add them manually every time. Is this possible? And if so, how? Cheers! Mark


Identifying coordinate system for Jersey

I'm trying to plot some X,Y coordinates which should be located on Jersey (the British dependency, not the state). The metadata that came with the points is as follows:               Coordinate System: Transverse_Mercator     False_Easting: 500000.000000     False_Northing: 0.000000     Central_Meridian: -3.000000     Scale_Factor: 0.999600     Latitude_Of_Origin: 0.000000     GCS_European_1950     Datum: D_European_1950     Prime Meridian: 0      An example coordinate is: 40844, 68194 However, when I try to put this into QGIS or ArcGIS, I end up with points near latlng 0,0. What am I doing wrong? How do I reference these points correctly, so I can plot them over a basemap?


Flip labels 180° with CartoCSS

How can I flip labels on my lines upside down? I am styling some OSM data and the cartocss is currently               #streets{      text-size: 14;      text-name: [NAME];      text-face-name: 'ATRotSemSanLigIta Regular';      text-fill: #000;      text-halo-fill: fadeout(white, 40%);      text-halo-radius: 2;      text-placement: line;      text-dy: 12;      }      I think its via text-orientation but cannot get it to fire


Building Qgis-1.8 on Scientific Linux - a sip error occured

I'm on Scientific Linux 6.3 and after trying to build Qgis 1.8 fter "ccmake" I got the error: * * * [ 89%] Built target translations [ 89%] Generating analysis/sipanalysispart0.cpp, analysis/sipanalysispart1.cpp, analysis/sipanalysispart2.cpp, analysis/sipanalysispart3.cpp sip: Usage: sip [-h] [-V] [-a file] [-c dir] [-d file] [-e] [-g] [-I dir] [-j #] [-m file] [-p module] [-r] [-s suffix] [-t tag] [-w] [-x feature] [-z file] [file] make[2]: *** [python/analysis/sipanalysispart0.cpp] Error 1 make[1]: *** [python/CMakeFiles/python_module_qgis_analysis.dir/all] Error 2 make: _*_ [all] Error 2 * * * here's my ccmake configuration screen: BINDINGS_GLOBAL_INSTALL OFF   BISON_EXECUTABLE /usr/bin/bison   BUILD_TESTING ON   CMAKE_BUILD_TYPE   CMAKE_INSTALL_PREFIX /usr/local   DART_ROOT DART_ROOT-NOTFOUND   ENABLE_TESTS ON   EXPAT_INCLUDE_DIR /usr/include   EXPAT_LIBRARY /usr/lib64/libexpat.so   FLEX_EXECUTABLE /usr/bin/flex   GDAL_CONFIG /usr/local/bin/gdal-config   GDAL_CONFIG_PREFER_FWTOOLS_PAT /bin_safe   GDAL_CONFIG_PREFER_PATH /bin   GDAL_INCLUDE_DIR /usr/local/include   GDAL_LIBRARY /usr/local/lib/libgdal.so   GEOS_CONFIG /usr/bin/geos-config   GEOS_CONFIG_PREFER_PATH /bin   GEOS_INCLUDE_DIR /usr/include   GEOS_LIBRARY /usr/lib64/libgeos_c.so   GEOS_LIB_NAME_WITH_PREFIX -lgeos_c   GITCOMMAND /usr/bin/git   GIT_MARKER /home/tomas/Downloads/libspatialindex-master/ GRASS_PREFIX /usr/local/grass-6.4.3svn   GSL_CONFIG /usr/bin/gsl-config   GSL_CONFIG_PREFER_PATH /bin   GSL_EXE_LINKER_FLAGS -Wl,-rpath,   PEDANTIC ON   POSTGRESQL_PREFIX /usr/pgsql-9.2   POSTGRES_CONFIG /usr/pgsql-9.2/bin/pg_config   POSTGRES_CONFIG_PREFER_PATH /usr/pgsql-9.2/bin   POSTGRES_INCLUDE_DIR /usr/pgsql-9.2/include   POSTGRES_LIBRARY /usr/pgsql-9.2/lib/libpq.so   PROJ_INCLUDE_DIR /usr/include   PROJ_LIBRARY /usr/lib64/libproj.so   PYRCC4_PROGRAM /usr/bin/pyrcc4   PYTHON_LIBRARY /usr/lib64/libpython2.6.so PYUIC4_PROGRAM /usr/bin/pyuic4   QSCINTILLA_INCLUDE_DIR QSCINTILLA_INCLUDE_DIR-NOTFOUND   QSCINTILLA_LIBRARY QSCINTILLA_LIBRARY-NOTFOUND   QT_QMAKE_EXECUTABLE /usr/bin/qmake-qt4   QWT_INCLUDE_DIR /usr/include/qwt   QWT_LIBRARY /usr/lib64/libqwt.so   SPATIALINDEX_INCLUDE_DIR /usr/local/include/spatialindex   SPATIALINDEX_LIBRARY /usr/local/lib/libspatialindex.so   SPATIALITE_INCLUDE_DIR SPATIALITE_INCLUDE_DIR-NOTFOUND   SPATIALITE_LIBRARY SPATIALITE_LIBRARY-NOTFOUND   SQLITE3_INCLUDE_DIR /usr/include   SQLITE3_LIBRARY /usr/lib64   TXT2TAGS_EXECUTABLE TXT2TAGS_EXECUTABLE-NOTFOUND   WITH_APIDOC OFF   WITH_ASTYLE OFF   WITH_BINDINGS ON   WITH_DESKTOP ON   WITH_GLOBE OFF PYUIC4_PROGRAM /usr/bin/pyuic4   QSCINTILLA_INCLUDE_DIR QSCINTILLA_INCLUDE_DIR-NOTFOUND   QSCINTILLA_LIBRARY QSCINTILLA_LIBRARY-NOTFOUND   QT_QMAKE_EXECUTABLE /usr/bin/qmake-qt4   QWT_INCLUDE_DIR /usr/include/qwt   QWT_LIBRARY /usr/lib64/libqwt.so   SPATIALINDEX_INCLUDE_DIR /usr/local/include/spatialindex   SPATIALINDEX_LIBRARY /usr/local/lib/libspatialindex.so   SPATIALITE_INCLUDE_DIR SPATIALITE_INCLUDE_DIR-NOTFOUND   SPATIALITE_LIBRARY SPATIALITE_LIBRARY-NOTFOUND   SQLITE3_INCLUDE_DIR /usr/include   SQLITE3_LIBRARY /usr/lib64   TXT2TAGS_EXECUTABLE TXT2TAGS_EXECUTABLE-NOTFOUND   WITH_APIDOC OFF   WITH_ASTYLE OFF   WITH_BINDINGS ON   WITH_DESKTOP ON   WITH_GLOBE OFF WITH_GRASS ON   WITH_INTERNAL_QEXTSERIALPORT ON   WITH_INTERNAL_QWTPOLAR ON   WITH_INTERNAL_SPATIALITE ON   WITH_MAPSERVER OFF   WITH_POSTGRESQL ON   WITH_PYSPATIALITE OFF   WITH_PY_COMPILE OFF   WITH_QSCIAPI ON   WITH_QTMOBILITY OFF   WITH_SPATIALITE OFF   WITH_STAGED_PLUGINS ON   WITH_TOUCH OFF   WITH_TXT2TAGS_PDF OFF   _find_lib_python_py /home/tomas/Downloads/libspatialindex-master/ _find_pyqt_py /home/tomas/Downloads/libspatialindex-master/ _find_qsci_py /home/tomas/Downloads/libspatialindex-master/ _find_sip_py /home/tomas/Downloads/libspatialindex-master/


What is the correct variable type for a single value in raster calculator, modelbuilder?

The equation includes several raster and several single values, and I want to do it in raster calculator, modelbuilder for the purpose of multiple calculations. In raster part, it is ok to select raster band, but how about the single values? I have selected any value under the function of create variable, but it does not work. The expression is Cos("%Solar Zenith Angle%") * Cos("%Slope%") + Sin("%Solar Zenith Angle%") * Sin("%Slope%") * Cos("%Solar Azimuth Angle%" - "%Aspect%") P.S. Slope and aspect are both raster, and Solar Zenith Angle and Solar Azimuth Angle are only single values. It works, when I use raster calculator directly, so I think the problem probably comes from the variable type. Any hint? Thanks!


Seeking ArcGISTiledMapServiceLayer Sample

I'm trying to use ArcGISTiledMapServiceLayer to show a cached set of image tiles on our local server. There is good help on the arcgis developer's site but I can't seem to find good examples. None of the samples they list actually call this method. I'm using esri javascript api version 3.7


Help with building a batch model to extend radiating lines to nearest feature for multiple points

I'm new to using modelbuilder in ArcGIS 10 and was hoping I could get some help for creating a batch model to extend lines from points to the nearest feature. ![Example Point](http://i.stack.imgur.com/1FJE2.jpg) Here's what I need it to do: 1) Select a specific point and all of its associated radiating lines (n=32, spaced at equal 11.25 deg intervals) 2) Extend lines from this point to the nearest land feature or max distance (50 km) 3) Iterate this process for all unique points with radiating lines. 4) Merge these layers together to create one shapefile with all extended radiating lines and points. I'm using a pre-built tool that extends lines to nearest feature by converting the feature polygon shapefile to a line feature and then intersecting this with the radiating lines (http://resources.arcgis.com/gallery/file/geoprocessing/details?entryID=A23B4FB2-1422-2418-A056-231051051FEB). The problem I have if I run this tool alone on the entire radiating line layer and a polygon feature layer is that the tool will trim the lines to the nearest line feature which is sometimes another radiating line. ![Extend Line Issue](http://i.stack.imgur.com/dfarL.jpg) So far I've been able to successfully create 3 separate models to get the desired results. I was hoping to incorporate these three models into a single model that can run start to finish and not fill up my hard drive with batch files, just a single output file. Here is what I'm using: Model 1 - Create Unique Features from unique IDs ![Select by Attribute](http://i.stack.imgur.com/KZaBK.jpg) Model 2 - Extend lines to nearest feature of each Unique line feature ![Extend Lines](http://i.stack.imgur.com/FMd34.jpg) Model 3 - Merge extended line features ![Merge Features](http://i.stack.imgur.com/Q74Vb.jpg) Resulting final output: ![Final Output Result](http://i.stack.imgur.com/rWg71.jpg) My radiating line layer is setup in a grid with center points every ~1 km or so and I want to extend each radiating line to the nearest feature or maximum of 50 km (whichever comes first). Thanks for the help and please excuse any ignorance I may have for creating models as this is my first try.


Understanding Scale and Resolution between WGS84 and Web Mercator

This might be very basic question, am trying to understand the relationship between scale, resolution and coordinate system. First, let me explain the problem I have a web mapping application (using ESRI silverlight API) which uses dynamic service which is in WG84 coordinate system. Application supports Web Mercator projection as well. i.e on fly map projection is set to WGS_1984_Web_Mercator_Auxiliary_Sphere. Note that published map service is still in WGS84 only. The one of main layer has set a specific scale range and it works fine in WGS84, whereas when application is switched to Web Mercator polygons are not appearing i.e scale does not suit to web Mercator projection. Conclusion - How to control layer scale on the web application which uses dual coordinate system. ? We do not have luxury to create a seperate map service in web mercator at this point of time. Any help or pointers is appreciated.


Silverlight API like OpenLayers?

Is there any Silverlight based WebGIS API like OpenLayers?


Howto setup osm2psql

I'm following these instructions to setup `osm2psql` . I need it to import `osm` data file inside a `PostGIS DB`. The following steps worked fine:               createdb -E UTF8 -O user mydb     createlang plpgsql mydb      I successfully added PostGIS extensions too:               psql mydb < postgis.sql     psql mydb < spatial_ref_sys.sql      I start getting problems when trying to alter table's owner:               psql -d mydb -c "ALTER TABLE geometry_columns OWNER TO user"     psql -d mydb -c "ALTER TABLE spatial_ref_sys OWNER TO user"      both above commands produce the following syntax error: > ERROR: syntax error at or near "user" LINE 1: ALTER TABLE geometry_columns > OWNER TO user I've also tried to add a semicolon at the end of the query, but I still get the same error:               psql -d mydb -c "ALTER TABLE geometry_columns OWNER TO user;"     psql -d mydb -c "ALTER TABLE spatial_ref_sys OWNER TO user;"      I'm not so confident with SQL nor with Postgres. Could anyone tell me where's my mistake?


Line feature, Merge and Dissolve

I have a layer with several polygons and a layer with line above these polygons. Its like a map and a road network on it. I have to find out the length of line in each polygon. I used the intersect tool to spit the lines. However, I have three roads(from same layer) and when i intersect it. Instead of getting three different attribute, I get three lines but one single line attribute. Could someone tell me how to measure the length of each line.


How could I rate roads for scenic drives?

relative GIS newbie here. I've been working on a personal project to rate roads on how nice a ride they'd be on a motorcycle. I wrote a Python program to work through road data in the TIGER dataset (PostGIS) and apply a small number of metrics:   1. Road variance (twistyness)   2. Road elevation variance   3. Does the road pass by a body of water   4. Does the road go through a park The results of applying the metrics have been a good start, but they are far from perfect. So I'm trying to decide on some new metrics to apply.   1. Check land coverage around road. Riding along rolling hillsides is better than a forest which is better than an industrial park.   2. Road condition (paved or unpaved)   3. Number of stop signs, street lights encountered   4. Utilize viewshed analysis to check if a body of water is actually visible from road   5. Identify mountain views and use viewshed analysis to see if mountain can be seen from road (think Great Smokey Mountains)   6. Apply historical traffic data I need the advice of some GIS professionals. Do these sound feasible, or even make sense? Can you think of any other things I should try? Most importantly, where can I get data for the valid ideas?


How to create a new table with point geometry column using QGIS DB Manager?

I have been trying to use QGIS DB Manager to create an empty table (QGIS 2.0 on Win7). My hope is that I can make an empty point file and use it to add data to, via heads-up digitizing (like you would when you create an empty shapefile). But when I do this, the table that is created, and added to QGIS does not have geometry, or the ability to digitize in. Any help would be appreciated Thanks.... ![enter image description here](http://i.stack.imgur.com/HJAqv.png)


Select points approx. 2000 metres from another point along a river?

![enter image description here](http://i.stack.imgur.com/DoxnM.jpg) I have a series of points representing a river network (See Image Above). Each point contains attributes on Latitude, Longitude, Z value and Length calculated using flow accumulation. The river network was created from Digital Elevation Models using hydrology tools in ArcGIS (Fill, Flow Direction, Flow Accumulation, Strahler Order > 4). I also have a polyline shapefile that also runs along this river network. Starting at the first point at the beginning of each network I would like to determine another point "downstream" that is approximately 2000 metres away (Or closest to 2000 metres). I would then like to calculate channel slope based on the difference in elevation divided by the difference in length (2000m) using the two points. I am aware that at the junctions there will be an issue, any suggestions on accomplishing this task in GIS to determine the point 2000m downstream and continuing downstream at junctions? I am using ArcGIS 10.1 with an ArcInfo license and also have access to QGIS and GrassGIS. I am familiar with using python scripts as well. Edit: Progress The stream polyline has the following attributes: x1: x coordinate of start point (Double) y1: y coordinate of start point (Double) x2: x coordinate of end point (Double) y2: y coordinate of end point (Double) length: length of polyline shape: shape of polyline startxy: [x1]&", "&[y1] (Text) endxy: [x2]&", "&[y2] (Text) I am using the tool to make arrays `start = arcpy.da.FeatureClassToNumPyArray("polyline",["x1","y1"])` Dictionary               G ={}     >>> for (st,sh,le,en) in zip (start,shape,length,end):     ...     G[st]=(st,le,en)      Algorithm               def Downstream (p, x, G):     ...     e = G[p]     ...     if (IsNull(e)):     ...         return ("Not Found")     ...         if (x < 0):     ...             return ("Invalid")     ...             if (x < e.length):     ...                 return (Along (e.shape, x))     ...                 return (Downstream (e.end, x-e.length,G))      The Downstream function is receiving a runtime error where there is a key error. I have used G.keys() to see the keys, but they are not working when inputted in the function.


How can I calculate the distances between my points in sequence automatically?

I have a rookie problem (again). I am trying to measure distances between points and writing the calculated measure between these points in the attribute table. The points represents a vehicle's location based on gps datas according to existence location in time aspect. I could add the longtitude and latitude data from excel to a shape layer. ![table photo](http://i.stack.imgur.com/SC4hj.jpg) ![how the points seen in the map](http://i.stack.imgur.com/tvQic.jpg) After creating shape file, i could be able to measure the euclidean distances between the nodes, but if i will do the calculations manually, i might need to have immortal life. Heres my question, how i can calculate automatically the distances between the nodes and write the calculations in my table or excel or csv data. the distance will calculate according to the id's. I mean the first distance will be for FID 1 and 2; the second will be for 2-3, third 3-4 and etc. Please help me :) Thanks a lot.


How to convert a .tif with .tfw to a GeoTiff?

I have a tif image file, and a .tfw world file (created from OSM data with Mapertive). How can I (using linux command line) convert that to a GeoTIFF file? (i.e. I want to have one file, not 2). I'm sure it's possible with gdal or something.


Layers not aligning in ArcGIS10

I have two layers, one of points (locations of fruit trees) and one of Atlanta zip codes, in an ArcMap, but the layers are not aligning. The fruit trees are in a corner and the map is in the middle top. The fruit points were successfully converted to a shp file from a csv file. The two layers have the same projected coordinate system NAD_1983_StatePlane_Georgia_West_FIPS_1002_Feet and the same geographic coordinate system GCS_North_American_1983 I thought the error would be that the systems didn't match up, but that's not the case. Any ideas would be appreciated!