title: QGIS - Create buffer in meters

text: I'm very new to the GIS world, so my problem could be very stupid, but I'm going to try anyway. # Objective Given a list of coordinates in longitude/latitude, stored as a `.csv` file, I want to create a buffer with distance of `x` km around those coordinates. (In case this is relevant, these coordinates are locations of the societies in the SCCS dataset. These societies scatter all around the world.) # Problem I'm only able to create buffers with distance in radial degrees, but I want to do them in (kilo)meters. I'm aware of the following Q&A's, but following what's suggested therein doesn't seem to solve my problem:   * What is up with QGIS buffer tool units?   * What's the Workflow for buffering in meters/km using WGS84 layers?   * How to create a polygon (fixed width buffer) around a polygon in QGIS?   * QGIS - Change unit of measure from degrees to meters # What I have tried...   1. I start QGIS (v2.4), and `Add delimited text layer`   2. choose my `.csv` file and the x/y fields, click `OK`   3. select `WGS 84` as my CRS (also tried `NAD83` but didn't make a difference), click `OK`   4. right-click on layer and select `Save As...`, in the dialog box, choose the following and click `OK`: ![enter image description here](http://i.stack.imgur.com/IjGll.png)   5. add `sccs_meter.shp` as layer to the current project   6. Select `Vector` > `Geoprocessing Tools` > `Buffers` > set buffer distance as 10 The result is a buffer with radius of approximately 1068km, which suggests that buffer distance is 10 degrees rather than 10 meters. What did I do wrong here?


title: How to add markers to OSM base map in Google Maps API?

text:
I am using the example from this webpage to display my maps:               http://wiki.openstreetmap.org/wiki/Google_Maps_Example#More_examples     (Example - Using Google Maps API v3 setting OSM as a base map layer)      However, I need to add markers but I get a blank page. See code below:               <!DOCTYPE html>                   <meta charset="utf-8" />         <meta name="viewport" content="initial-scale=1.0, user-scalable=no" />         <meta name="apple-mobile-web-app-capable" content="yes" />         <title>OpenStreetMap with Google Maps v3 API</title>

                                  Please what am I doing wrongly.. Thanks


title: Georeferenced Tiffs displaying in the wrong location & scale when updating ArcGIS 10

text: I'm working on a project which involves georeferencing a large number of .tiff files to digitize data from them. All the tiffs which have already be georeferenced where done with ArcMap 10.0 without any service packs installed. In an effort to solve an issue with the pixels inverting and a certain zoom level, I've been experimenting with upgrading service packs. Each service pack I install causes some, but not all, of the previously georeferenced tiff files to display at a significantly smaller size, and in the incorrect location. The location change may just be do the the scaling problem though, since it is still near the correct location, I'm not positive though. Also, when I open the same map document on the other computer in the office running ArcMap 10.0 without any service packs, the tiffs are located where they should be and the proper size. I'm currently running ArcMap 10.0 with Service Pack 5 installed, and I've also installed the Raster Format Patch, neither of which have helped. I've done a few searches, and have not been able to find any solutions for this issue. Has anyone else run into this problem? Thanks, Chris


Where can I find spatial data on polar fish populations? I am looking specifically for polar cod, but any fish will do at this point in my project. I also need arctic ocean salinity, temperature, and sea ice coverage


title: Is there a typescript interface for "GeoXML" formats (such as WFS and WMS) apart from GeoJSON?

text: I want to work with JSON behind TypeScript interfaces but I'm not sure what the spec should be outside of GeoJSON. Is there a spec which is more encompassing then GeoJSON and includes things like a GetCapabilities response? For example, it is very obvious with ESRI because ArcGIS Server services have built-in json support via adding a query string. For example, http://sampleserver3.arcgisonline.com/ArcGIS/rest/services?f=json&callback=foo But GeoServer limits json support to GetFeature/GetFeatureInfo requests so it's not obvious what a GetCapabilies response might look like if a tool were to actually produce JSON. So my question is this:   1. Is GeoJSON format limited to spatial data?   2. If so, is there any other JSON standards/schemas related to WFS/WMS services that is more encompassing? NOTE: OpenLayers has WFS/WMS readers for various services. Presumably the resulting JSON conforms to some standard?   1. https://github.com/openlayers/ol3/blob/master/test/spec/ol/parser/ogc/wfs_v1_1_0.test.js   2. https://github.com/openlayers/ol3/blob/master/test/spec/ol/parser/ogc/wmscapabilities_v1_0_0.test.js


title: Why does connect to Excel spreadsheet through ArcPy give ERROR 000582?

text: My ultimate goal is to automate kernel density analysis on xy data from a table. I am trying to learn Python but I am very new. I built a simple model to take table data and display xy data. When I attempt to export the model as a Python script, the script fails. I do not have a programming background but I have programmers available to me. Any help or advice would be greatly appreciated.               # -*- coding: utf-8 -*-     # ---------------------------------------------------------------------------     # test.py     # Created on: 2014-02-12 13:14:37.00000     #   (generated by ArcGIS/ModelBuilder)     # Description:      # ---------------------------------------------------------------------------          # Import arcpy module     import arcpy               # Local variables:     Input_Table = "C:\\Users\\cbriglia\\Desktop\\GIS\\Worksheets\\accidents_jan_2013.xls\\Sheet1$"     Sheet1__Layer = "Sheet1$_Layer"     Ouput_Feature_Class = "C:\\Users\\cbriglia\\Desktop\\GIS\\Shapefiles\\acc_jan_2013_builder.shp"          # Process: Make XY Event Layer     arcpy.MakeXYEventLayer_management(Input_Table, "longitude", "latitude", Sheet1__Layer, "GEOGCS['GCS_North_American_1983_CSRS',DATUM['D_North_American_1983_CSRS',SPHEROID['GRS_1980',6378137.0,298.257222101]],PRIMEM['Greenwich',0.0],UNIT['Degree',0.0174532925199433]];-400 -400 1000000000;-100000 10000;-100000 10000;8.98315284119521E-09;0.001;0.001;IsHighPrecision", "")          # Process: Copy Features     arcpy.CopyFeatures_management(Sheet1__Layer, Ouput_Feature_Class, "", "0", "0", "0")      _Runtime error Traceback (most recent call last): File "", line 19, in File "c:\program files (x86)\arcgis\desktop10.1\arcpy\arcpy\management.py", line 6348, in MakeXYEventLayer raise e ExecuteError: ERROR 000582: Error occurred during execution._


title: QT designer form default text ignored in QGIS when used with sqlite db

text: I'd like to populate a table with a custom form, for which I'd like some default text to be set when opening the dialog. I have two columns ('Name' and 'Description'), each with text that should be put. When I use the UI in QGIS everything is working fine, i.e. using a shapefile, but when I use the same UI for my sqlite-db, I get NULL in the field instead of the desired default value.. ![enter image description here](http://i.stack.imgur.com/nQr2A.jpg) # edit: I just found something that might solve my problem: QGIS custom form: 'dynamic' default value However, I'm still keen to learn why the default value is ignored?


title: Sample classification datasets?

text: I was looking for some **publicly** available ground data classification datasets, specifically, locations in e.g. latitude/longitude with a description of the land cover/land use, and a reference e.g. Landsat image. The aim of this is to have a sample classification dataset with which to try out different classification algorithms. And yes, I could do this by hand, selecting random pixels from a landcover dataset, but I'd like to at least have some sort of ground truth to compare with and I'd rather use some freely available data that people have used for other things.


title: Converting multipart line into single parts using QGIS?

text: I have a shapefile in which a bunch of the lines are multipart. Sometimes this is due to joining ways that are not quite connected (gap less than a foot of real-world distance) and sometimes the endpoints of each part are at exactly the same place (thanks to snapping before joining). This is really annoying because it means that splitting does not work properly, among other lesser problems. I've tried every suggestion I've come across. GRASS v.clean.snap with tolerance 1 does nothing. Exporting to KML and removing the gaps in the KML file works but only if the parts are in the correct order and direction (otherwise I get garbage connecting lines). Exporting to GPX completely fails because GPX can only handle single-part lines. Am I missing something here? Why does this problem even exist? I understand why it happens when there is a slight gap, but I can't see any situation in which joining two topologically connected ways in a multipart line is a feature rather than a bug. Here (click "Click here to start download from sendspace") is a shapefile with two multipart lines. I-85 has a tiny gap (at the state line), while I-795 connects perfectly yet has three parts. Does anyone have a solution for this, one that can be batch-applied to a file with many lines?


title: CartoDB - renamed table and changed API calls but still failing

text: I used the SQL API to make a new table with some data from an existing table. I also renamed all the API calls in my code to point to the new table. However, no point markers show up on my map now. I'm using Carto.js layer.setSQL to SELECT * FROM new_table but still nothing shows up on the map. The table is public. Do I have to make a new visualization too? Any help would be appreciated.


title: calculate distance between points crossing the antimeridian

text: How can I calculate the distance between two points (lon/lat) if any of the points exceeds the antimeridian (+-180 longitude)? Im using the `distVincentyEllipsoid {geosphere}` to calculate the shortest distance between two points. But if any of the points crosses the antimeridian the distance will be very close to zero. Is there a way to go about this problem? I have seen threads on similar problems but not using `R`. Any pointers are highly appreciated, thanks!


title: how to transform sinusoidal cordinates in MATLAB

text: I am working with the Mod10a2. I want to convert MODIS HDFs with sinusoidal projections to WGS84 in MATLAB. i want to find the corresponding X & Y of the each pixel and then convert them latitude & longtitude.


title: Library to produce pretty print maps including rasters

text: I've come across a variety of libraries for easily producing maps for printing, in a fully reproducible way using some sort of code or configuration file. For example, Kartograph looks lovely, Vincent can do some cool stuff, and basemap allows integration of geographic data with matplotlib. However, I'm trying to produce maps which include raster data - and most of the options above only work with vector data. Are there any alternatives that will allow me to display rasters on my maps too? Of course, I can produce the sort of maps that I want in ArcMap or QGIS fairly easily, but it is difficult to make the process automatable and reproducible. For example, if I produce one map, and then a few weeks later want to produce the same map (exactly the same view extents, exactly the same zoom, exactly the same scaling for the raster stretches) with some different data, it gets quite tricky. By doing this in some sort of automated/scripted way I'd remove a lot of these issues. The key things I'd need are:   * Produces good looking maps   * Relatively concise (some of the basemap examples seem very long, and this is where something like Kartograph shines - see its documentation)   * Can display rasters and vectors, with configurable symbology/display for both   * Automatable Does anyone know of a tool that will allow me to easily do this? If not, what is the best 'hacky' solution you've found? I can't be the first person to run into this problem, but I can't find a good solution online.


title: Wherer is wrong with transforming a WGS84 [lon,lat] point onto google maps

text: I want to convert a longitude latitude point in WGS84 coordinate system to Google Maps(not google earth) coordinate, But when I put the converted point on google map, it always has a roughly 10km offset(moved to south) on y axis. First correct me if my understanding is wrong with the two projections:               Google Maps:         spheroid parameters: a = b = 6378137         projection: Mercator;         To WGS84 Datum offset: no, (means 0,0,0)           WGS84:         spheroid parameters: a = 6378137;b=6356752.314         projection: WGS84;(like no projection, the coordinate is just longitude and latitude)      What I did:               Convert the WGS84 longitude, latitude(we call it point1) to geocentric coordinate(point2) with WGS84's spheroid;     //because no datum offset between Google Maps and WGS84, no need to convert point2 to Google Maps' geocentric      Convert point2 to geodentic coordinate(point3) with Google map's spheroid     Project point3 with Mercator projection into meter coordinate(point4).     Linearly transform point4 onto google maps.      On internet everybody is saying that Google Maps' projection is 'EPSG:3857' which means a and b are the same 6378137, but if I just use standard WGS84's spheroid parameters, which means a and b are different, the whole process is always correct, the result is very accurate.


title: Using the geocode function with cursors

text: How do I use a cursor with a geocodeaddress function? I want to be able to: 1) read from a table 2) only geocode addresses(from table1) whose street number is not 0 using a cursor 3) then update a master table with the results from the geocode               # only try to geocode those addresses whose first street number digit is not zero            # Select the first char of the street number in the aRecord.ADDRESS1 field         MyStr = "!aRecord.ADDRESS1!.split(" ")[0]"         if MyStr != '0':             address_table = "table1"             address_locator = r"http://myservername/ArcGIS/rest/services/Composite_Locator/GeocodeServer"             geocode_result = "geocode_result"                  #Add XY fields and calculate XY             sr = arcpy.SpatialReference(4100)             with arcpy.da.UpdateCursor(geocode_result, ["SHAPE@XY", "X", "Y"], "", sr) as cursor:                 for row in cursor:                     row[1] = row[0][0]                     row[2] = row[0][1]                          # geocode is successful only if it returns a valid X (and Y)                      if (row[1] > 0.0):                     cursor.updateRow(row)                     Row_tobe_Inserted.X = row[1]                     Row_tobe_Inserted.Y = row[2]                     XY_Method = "Geocode"                      del row, cursor         else:             print "There are no records to be geocoded"


title: What's the use of the buffer function in field calculator?

text: I'm trying to find out how the **buffer** command in the filed calculator works. I tried to create a new field to my point shapefile (integer) with the following:               buffer ($geometry, 100)      but no geometries are added to the canvas and the filed in the table in empty. The `$geometry` attribute should refer to a specific field of the shapefile or not? Someone has successfully used this function?


title: OpenLayers and Mapserver-WMS-Layer disappear if the map is draged

text: I have a client for the WMS-Services of my mapserver. The client program is written in javascript and it uses Openlayers (v. 2.12). The map has as a base layer "Google satellite"-Layer and the mercator projection. The WMS layers are overlayers. Some of them have as a source data - raster data and some of them have as data - vector data. I have no problem with WMS "raster" layers. But I have a problem with WMS "vector" layers. If my Openlayers map is dragged too much to the left and the generated request to mapserver is started, the WMS "vector" layers go to be invisible (and it happens only on the lowest zoom level). I found out that the bbox in generated requests is in some way wrong because the mapserver response is empty: I tested the automatically generated request strings as links in my browser (firefox or Chrom). I have modified the mapfile and I added the mercator projection to it. But it did not help. Here is the begin of the map file: ` MAP   NAME "africa_southafrica_admin" PROJECTION   "init=epsg:4326"   "init=epsg:3857" "init=epsg:900913" END STATUS ON TRANSPARENT ON UNITS METERS WEB METADATA "wms_srs" "epsg:4326 epsg:3857 epsg:32733 epsg:900913" "wms_title" "ROCEEH Southafrica" "wms_onlineresource" "https://www.roceeh.uni- tuebingen.de/cgi-bin/mapserv?map=mapdata/MAP_88361.map" "wms_enable_request" "*" "ms_enable_modes" "*" "labelcache_map_edge_buffer" "-30" END END MAXSIZE 10000 SIZE 2048 2048 EXTENT -180.0 -89.0 180.0 89.0 FONTSET "font/fontset" LAYER NAME "SRTM_90m_Screening" STATUS OFF CLASS STYLE OUTLINECOLOR 102 255 51 END NAME "Satellite_SRTM_90m" LABEL TYPE BITMAP SIZE SMALL COLOR 102 255 51 END END TOLERANCE 3 PROJECTION "init=epsg:4326" "init=epsg:900913" END GROUP "Satellite_Data_Index" LABELITEM "name" METADATA "wms_title" "SRTM 90m" "wms_group_title" "Satellite Data Index" "wms_abstract" "No information available." "wms_include_items" "all" "gml_include_items" "all" "gml_geometries" "the_geom" "gml_the_geom_type" "multipolygon" END ...` Here two Requests to Mapserver: the first don't work and the second is fine: 1) https://www.roceeh.uni-tuebingen.de/cgi- bin/mapserv?map=mapdata/MAP_88361.map&FORMAT=image%2Fpng&LAYERS=SRTM_90m_Screening&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&SRS=EPSG%3A3857&BBOX=-45940489.454273,-7333063.5634033,-18555242.460298,12831635.991646&WIDTH=1399&HEIGHT=1030 2)https://www.roceeh.uni-tuebingen.de/cgi- bin/mapserv?map=mapdata/MAP_88361.map&FORMAT=image%2Fpng&LAYERS=SRTM_90m_Screening&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&SRS=EPSG%3A3857&BBOX=-13203427.488628,-10777010.309341,14181819.505347,9387689.245708&WIDTH=1399&HEIGHT=1030 My Question is: what I can do or how can I control the automatically generated Requests to avoid the described misbehavior. Thanks in advance, ZK.


title: Android Tablet KML/KMZ App for polygons w/offline & GPS capabilities?

text: I am looking for an Android app which allows me to view and query polygons stored in KML and/or KMZ with a GPS point representing my location and offline capabilities. My KMZ files are being output from ArcGIS 10.2.2 representing some several thousand features (lakes, ponds, etc.). I would like to be able to view these features by navigating to them via GPS. Previous poking around online has suggested that Backcountry Navigator (BCN) & Gaia GPS (Gaia) would be good places to start. I was able to load the large the large KML into BCN, but the polygons are serrated and the Object IDs are not always readable. Ideally, I could click on one of the features and look at the attributes. Gaia had issues loading such a large file, but the user interface is very agreeable. Other posts on GIS StackExchange have suggested Locus. After downloading the free app, I found that there were a number of issues with obtaining offline apps. For whatever reason, after trying a couple of WiFi connections, I was not able to download the tiles to my 2013 Nexus 7 (Android 4.4). Conversely, BCN & Gaia downloaded the offline maps with ease. Does anyone have a recommendation? Bonus points if the app allows the overlay of large raster files (~200 km^2 with 1 m resolution).


title: OpenStreetMap default style for roads

text: I'm using the OpenStreetMap plugin for QGIS and I've successfully rendered a .osm file (lines). I've tried a few styles from github but so far none of them label all of the streets like the osm default style. Is the default style available somewhere? And what format should I be looking for for a .osm file, xml, sld, qml.


title: Calculating Polygon Width in ArcGIS

text: Is there an easy to calculate the width of a polygon using ArcGIS 9.3.1 or 10? I found some scripts for 9.1 but they will not work. I can use width at widest point, narrowest point, or an average. It does not need to be exact but needs to be somewhat automated because I have a couple hundred to calculate. TIA!


title: How to account for Colour Blindness when designing maps?

text: Depending on what you read, 7 to 15% of the general population has some form of colour blindness. That's a significant amount of people. Do you try to account for this in your map designs? If so, how? Do you handle digital map design differently from hardcopy? Any indispensable resources?


title: How to Save a Raster or Polygon to ArcMap Table of Contents in C#?

text: Just as the title says, I want to save the Raster to the table of contents. I have a Raster displaying on the ArcMap IDisplay, but I can't figure out how to save it to the Table of Contents in ArcMap. The save to TOC will come after a button is pressed in ArcMap. Looking for code here. C# of VB.NET will be fine! Thanks all!


title: .NET console application running super slow all of the sudden

text: I have a standalone .NET console application that (through ArcObjects) processes DWG files, extract coordinates, and pushes them to SQL Server. It's smoking fast and can process a DWG in a matter of seconds. It's been running fine in production for quite a while now (over a year). All of the sudden last Wednesday it started running dead slow (40x longer). My server had a major power failure on the Monday night before this all started going wrong. When the server came back up, iSCSI drives were missing, all kinds of stuff was jacked up and it look 4-5 guys in infrastructure hours to get it all back up. I just found out about my process running slow today. My question is this: Does anyone have any idea what I could look for as the culprit in something like this. The process runs, just really, really sloooooow. Like its CPU starved. If it was permissions, it would just fail. I don't expect to get an answer from my infrastructure team. Any insight is greatly appreciated. EDIT: We just realized that ArcGIS Server hasn't written to any log files since this hard crash. The plot thickens... Another edit: The drive this executable resides on is connected through iSCSI. I don't know a whole lot about iSCSI, but we are wondering if this is a communications issue between the server blade and iSCSI (which I think communicates via a fiber card). I have moved the .NET application over to one of the physical drives on the blade and we'll see what happens...


title: Connect to PostgreSQL from ArcMap 10.2 failed

text: I have a database server PostgreSQL and Postgis. I want to connect to database from ArcMap 10.2 , I tried **Add Database Connection** from arcmap menü. I typed my connection informations and clicked database selection box, an error occured as following. My connection info is true. I can connect from pgAdmin to database. ![enter image description here](http://i.stack.imgur.com/XSnPz.png) I did not install ArcSDE to database server. I read before that I do not need SDE after 10.0 version.


title: How do I get Visual Studio to run EsriRegasm.exe as administrator?

text: When run Visual Studio 10 as administrator and build a project with this in my csproj:                 <Target Name="BeforeClean">         <Exec WorkingDirectory="$(CommonProgramFiles)\ArcGIS\bin"            Command="esriRegasm.exe "$(TargetPath)" /p:Desktop /u "            Condition="Exists('$(TargetPath)')" />       </Target>       <Target Name="AfterBuild">         <Exec WorkingDirectory="$(CommonProgramFiles)\ArcGIS\bin"          Command="esriRegasm.exe "$(TargetPath)" /p:Desktop " />       </Target>      It is able to do the clean (unregister) without any problems. However it complains saying ... > Registration failed. Could not write to disk. ... when it does the AfterBuild. (Notice I've removed the `/s` option on the command line.) I have a bat file that can call EsriRegasm.exe without any problems when run as administrator. However, when I run it as a non-admin I get the same error, which is expected. Batch files run as admin results in spawned processes that are also run as admin. Can Visual Studio do this too? **Is there some option I can add to the csproj file to make it run EsriRegasm.exe as admin?** I've already set my UAC to "never notify", as suggested by kb 39158. And set the file properties on EsriRegasm.exe to run as administrator.


title: ogr2ogr converting to shapefile - how to select feature types?

text: Shapefiles can only have one geometry type, but many other formats (kml, geojson) can have multiple types. When converting to shapefiles, is it possible to to tell ogr2ogr to create multiple shapefiles, one for each type? It seems like the "-where" option might be useful but the man page does not explain the syntax. For example, here's a command that fails:               $ wget http://a841-tfpweb.nyc.gov/jackson-heights/wp-content/themes/tfp/kml/transit.kml     $ ogr2ogr -f "ESRI Shapefile" transit.shp transit.kml     Warning 6: Normalized/laundered field name: 'Description' to 'Descriptio'     ERROR 1: Attempt to write non-linestring (POINT) geometry to ARC type shapefile.     ERROR 1: Terminating translation prematurely after failed     translation of layer Transit (use -skipfailures to skip errors)


title: How to add ocean_basemap in QGIS ?

text: Has anyone added the Ocean Base map to QGIS? I was able to add the Open Layers plugin and get the "land" basemap (among others), but not the ocean. Thanks, Mike


title: How to properly install Cartaro GeoCMS?

text: I have been trying to install Cartaro the drupal GeoCMS for a while without success. I have properly installed Geoserver (running fine), Postgresql and postgis 1.5 enabled but when i try to install Cartaro it does not detect PostGIS version and neither does it allow me to change anything manually. As this is a new software and the community and support is minimal still i do not know what is the right approach to solve this issue. Any advice would be helpful.


title: Is IPolygon2.QueryExteriorRingsEx Method not working in ArcGIS version 10.1 SP1?

text: I am updating my addins from 10.0 to 10.1 and my code is crashing on the IPolygon2.QueryExteriorRingsEx Method. I understand there is something strange going on with this method because Developer Help says it does not work in C# .Net (See remarks: "Does not work in .NET. Use Polygon4.get_InteriorRingBag instead.") Under remarks it also states that this method only accepts an array of type IRing for exteriorRings. Using an array of IRing2 won't work. I am using iRing. All worked great in 10.0 but the method now crashes if I attempt to query more that a single exterior ring. (Querying a polygon with one exterior ring passes) **Can someone confirm this behaviour before I attempt to re-write this procedure using the Polygon4.get_InteriorRingBag method instead?** Procedure below - the problem line is inside the do while loop               Public Sub PolygonsToPolylines(ByVal sourceFeatureLayer As ESRI.ArcGIS.Carto.IFeatureLayer, ByVal destFeatureLayer As ESRI.ArcGIS.Carto.IFeatureLayer)     On Error GoTo trap              Dim MxApplication As ESRI.ArcGIS.ArcMapUI.IMxApplication = TryCast(My.ArcMap.Application, ESRI.ArcGIS.ArcMapUI.IMxApplication)              Dim pEditor As ESRI.ArcGIS.Editor.IEditor2         Dim pEditLayers As ESRI.ArcGIS.Editor.IEditLayers         Dim pActiveView As ESRI.ArcGIS.Carto.IActiveView         Dim pEnumFeature As ESRI.ArcGIS.Geodatabase.IEnumFeature         Dim pFeature As ESRI.ArcGIS.Geodatabase.IFeature         Dim pPolygon As ESRI.ArcGIS.Geometry.IPolygon2         Dim pTempPolyline As ESRI.ArcGIS.Geometry.ITopologicalOperator         Dim pNewFeature As ESRI.ArcGIS.Geodatabase.IFeature         Dim pPolygon2 As ESRI.ArcGIS.Geometry.IPolygon2         Dim pPolyline As ESRI.ArcGIS.Geometry.IPolyline         Dim pPolylinePointColl As ESRI.ArcGIS.Geometry.IPointCollection         Dim pRings() As ESRI.ArcGIS.Geometry.IRing         Dim pRing As ESRI.ArcGIS.Geometry.IRing         Dim pRings2() As ESRI.ArcGIS.Geometry.IRing         Dim pRing2 As ESRI.ArcGIS.Geometry.IRing              'new         Dim pFeatureSelection As ESRI.ArcGIS.Carto.IFeatureSelection         Dim pSelectionSet As ESRI.ArcGIS.Geodatabase.ISelectionSet         Dim pFeatureCursor As ESRI.ArcGIS.Geodatabase.IFeatureCursor = Nothing              Dim r As Long, i2 As Long, r2 As Long, c As Long, c2 As Long         Dim d As Long 'progress dialog counter              Dim source3D As Boolean, dest3D As Boolean              Has_3D_value(sourceFeatureLayer.FeatureClass, source3D) 'determine whether source features class is 3D         Has_3D_value(destFeatureLayer.FeatureClass, dest3D) 'determine whether destination features class is 3D                   'Get a handle to the Editor extension         pEditor = GetEditorFromArcMap(MxApplication)              If pEditor Is Nothing Then Exit Sub              pEditLayers = pEditor 'QI         pActiveView = pEditor.Map              If pEditor.EditState = ESRI.ArcGIS.Editor.esriEditState.esriStateNotEditing Then             MsgBox("You must be editing to use this feature!", MsgBoxStyle.Information)            Exit Sub         End If              'QUERY Layer selection to get cursor'''''''''''''''''''''''''''''''''''''''''''''''         pFeatureSelection = sourceFeatureLayer              pSelectionSet = pFeatureSelection.SelectionSet         d = pSelectionSet.Count         If d < 1 Then             MsgBox("You must select at least 1 feature!") : Exit Sub         End If              'retreive selection into a cursor         pSelectionSet.Search(Nothing, False, pFeatureCursor)         ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''              'Set up Progress Bar''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''              'Create a CancelTracker         'Dim trackCancel As ESRI.ArcGIS.esriSystem.ITrackCancel = New ESRI.ArcGIS.Display.CancelTrackerClass '10.0          Dim trackCancel As ESRI.ArcGIS.esriSystem.ITrackCancel = New ESRI.ArcGIS.Display.CancelTracker '10.1 update              Dim progressDialogFactory As ESRI.ArcGIS.Framework.IProgressDialogFactory = New ESRI.ArcGIS.Framework.ProgressDialogFactoryClass              'Set the properties of the Step Progressor         Dim int32_hWnd As System.Int32 = My.ArcMap.Application.hWnd         Dim stepProgressor As ESRI.ArcGIS.esriSystem.IStepProgressor = progressDialogFactory.Create(trackCancel, int32_hWnd)         ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''              'Set the properties of the Step Progressor         stepProgressor.MinRange = 0         stepProgressor.MaxRange = d         stepProgressor.StepValue = 1         stepProgressor.Message = "Copying..."              'Create the ProgressDialog. This automatically displays the dialog         Dim progressDialog2 As ESRI.ArcGIS.Framework.IProgressDialog2 = CType(stepProgressor, ESRI.ArcGIS.Framework.IProgressDialog2) ' Explict Cast              ' Set the properties of the ProgressDialog         progressDialog2.CancelEnabled = True         progressDialog2.Description = "Copy Features"         progressDialog2.Title = "Copying..."         progressDialog2.Animation = ESRI.ArcGIS.Framework.esriProgressAnimationTypes.esriDownloadFile         ' Step. Do your big process here.         Dim boolean_Continue As System.Boolean         boolean_Continue = True         Dim i As System.Int32         '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''              'Start an edit operation         pEditor.StartOperation()              pFeature = pFeatureCursor.NextFeature              Do While Not pFeature Is Nothing                  'Progress Bar''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''             Dim statusBar As ESRI.ArcGIS.esriSystem.IStatusBar = TryCast(My.ArcMap.Application.StatusBar, ESRI.ArcGIS.esriSystem.IStatusBar)             statusBar.Message(0) = i.ToString             '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''                  If pFeature.Shape.GeometryType = ESRI.ArcGIS.Geometry.esriGeometryType.esriGeometryPolygon Then                 c = c + 1                 pPolygon2 = pFeature.ShapeCopy                 SimplifyGeometry(pPolygon2)                      r = pPolygon2.ExteriorRingCount                 If r > 0 Then                      r = r - 1                     ReDim pRings(r)                     pPolygon2.QueryExteriorRingsEx(pPolygon2.ExteriorRingCount, pRings(0))                          For i = 0 To r                         pRing = pRings(i)                              r2 = pPolygon2.InteriorRingCount(pRing)                              If r2 > 0 Then                             r2 = r2 - 1                             ReDim pRings2(r2)                             pPolygon2.QueryInteriorRingsEx(pRing, pPolygon2.InteriorRingCount(pRing), pRings2(0))                             For i2 = 0 To r2                                 pRing2 = pRings2(i2)                                      pPolylinePointColl = New ESRI.ArcGIS.Geometry.Polyline                                 pPolylinePointColl.AddPointCollection(pRing2)                                 pPolyline = pPolylinePointColl 'QI                                 SimplifyGeometry(pPolyline)                                      SimplifyGeometry(pPolyline)                                 pNewFeature = destFeatureLayer.FeatureClass.CreateFeature                                 pNewFeature.Shape = pPolyline                                 CopyFieldValues(pFeature, pNewFeature) 'copy matching field values                                 pNewFeature.Store()                                 c2 = c2 + 1                             Next                         End If                              pPolylinePointColl = New ESRI.ArcGIS.Geometry.Polyline                         pPolylinePointColl.AddPointCollection(pRing)                         pPolyline = pPolylinePointColl 'QI                         SimplifyGeometry(pPolyline)                              pNewFeature = destFeatureLayer.FeatureClass.CreateFeature                              If (dest3D = True And source3D = False) Or (dest3D = True And source3D = True) Then                             SetZAware(pPolyline) 'make geometry zAware                             'FUTURE UPDATE = COPY or ASSIGN 3D Values to all geometry points                         End If                              If dest3D = False And source3D = True Then                             RemoveZAware(pPolyline) 'remove zAware from geometry                         End If                              pNewFeature.Shape = pPolyline                         CopyFieldValues(pFeature, pNewFeature) 'copy matching field values                         pNewFeature.Store()                         c2 = c2 + 1                              'Check if the cancel button was pressed. If so, stop process                         boolean_Continue = trackCancel.Continue                         If Not boolean_Continue Then                           Exit For                         End If                     Next                 End If                  End If                  pFeature = pFeatureCursor.NextFeature         Loop              'Done         trackCancel = Nothing         stepProgressor = Nothing         progressDialog2.HideDialog()         progressDialog2 = Nothing              MsgBox("Succesfully created " & c2 & " lines from " & c & " selected polygons.")              'Complete the edit operation         pEditor.StopOperation("Copy Polygons to Polylines")              'Flag the area of the new feature for refreshing         pActiveView.Refresh()              Exit Sub          trap:         MsgBox(Err.Description)         pEditor.AbortOperation()          CancelProgressBar:         'Progress cleanup         progressDialog2.HideDialog()         trackCancel = Nothing         stepProgressor = Nothing         progressDialog2 = Nothing          End Sub


title: Quantitative evidence supporting Solid State Drive (SSD) adoption for ArcGIS Desktop workstations?

text: Has anyone seen quantitative evidence supporting the use of a SSD (solid state drive) in an ESRI ArcGIS Desktop workstation? Or any GIS workstation for that matter? I keep reading that SSDs can be a huge performance boost but I have not seen any numbers to support the claim. I have a feeling that the productivity increase could be comparable to a switch from single to dual monitor setup.


title: Script tool Value ERROR 000735: Output Layer: Value is required?

text: I've been struggling to get my script tool to run without receiving the following error:               <class 'arcgisscripting.ExecuteError'>: Failed to execute. Parameters are not valid.     ERROR 000735: Output Layer: Value is required     Failed to execute (SaveToLayerFile)      The script processes fine when run in PythonWin, it is only the script tool that is giving me the problem. I'm not understanding what kind of "value" it is looking for for an "Output" The following is my script and I tried to bold the line it is choking on, but it's not displaying as bold in the preview so I don't know if it will come out that way. It's the saveToLayerFile_management line in this section of code about 3/4 of the way through the entire script:               # Make feature layer for contours save it and apply symbology layer     #try:     arcpy.MakeFeatureLayer_management("contoursClip", "contoursClipLayer")     **arcpy.SaveToLayerFile_management("contoursClipLayer", contoursClipLyr)**     arcpy.ApplySymbologyFromLayer_management("contoursClipLayer", contoursSymb)          #except:         #print "make feature layer/apply symbology for contours failed."      Can anyone enlighten me as to why it does not like this or what I am apparently missing? It is defined in the script tool as a layer file data type, with a derived/output property type/direction. Thanks in advance!               import arcpy     from arcpy import env     from arcpy.sa import *          # Set the current workspace     env.workspace = r"C:\Project2.gdb"          #Define variables     snowAmt_In = "SnowAmt_in"     snowAmt_Cm = "SnowAmt_cm"     contourInterval = 10     numberZones = 7     OKX = r"C:\OKX.lyr"     OKXcounties = r"C:\OKXcounties.lyr"     #contoursClipLayer = r"C:\contoursClipLayer.lyr"     contoursClipLyr = r"C:\contoursClipLyr.lyr"     #clipOKXLayer = r"C:\clipOKXLayer.lyr"     clipOKXLyr = r"C:\clipOKXLyr.lyr"     contoursSymb = r"C:\contoursSymb.lyr"     rasterSymb = r"C:\rasterSymb.lyr"     contourLabelText = r"C:\contourLabelText.lyr"     mxd = r"C:\Project2.mxd"     mxd1 = arcpy.mapping.MapDocument(mxd)     mxdSave = r"C:\Projectmap.mxd"     gdb = r"C:\Project2.gdb"     df = arcpy.mapping.ListDataFrames(mxd1)[0]     contourLabel = r"C:\contourLabel.lyr"          # add field for cm          try:         arcpy.AddField_management ("dec2009data", snowAmt_Cm, "float", "5", "2")          except:         print "Field already exists"          # Make a feature layer for "dec2009data"     try:         arcpy.MakeFeatureLayer_management ("dec2009data", "dec2009dataLayer")          except:         print "File already exists"          #Create update cursor for the SnowAmt_Cm field     snowCmRows = arcpy.UpdateCursor("dec2009data")     snowCm = snowCmRows.next()          while snowCm:         snowInch = snowCm.getValue(snowAmt_In)         #convert inches to cm         multiplier = 2.54         snowInCm = snowInch * multiplier         #print snowInCm              # Write the snow amount (cm) to SnowAmt_Cm field           snowCm.setValue(snowAmt_Cm, snowInCm)         snowCmRows.updateRow(snowCm)         snowCm = snowCmRows.next()          # Remove temp layer       arcpy.Delete_management("dec2009dataLayer")             del snowCm, snowCmRows               # Interpolate point data              # Check out the ArcGIS Spatial Analyst extension license     arcpy.CheckOutExtension("Spatial")          try:         # Execute Natural Neighbor         outNatNbr = NaturalNeighbor("dec2009data", snowAmt_Cm)         # Save the output         outNatNbr.save("outNatNei")     except:         print "the natural neighbor interpolation file already exists"                    # Add contours to the raster         # Execute Contour tool     try:         Contour("outNatNei", "contours", contourInterval)     except:         print "the contour file already exists"                    #Clip contours to OKX CWA boundary         # Execute vector Clip tool     try:         arcpy.Clip_analysis("contours", OKX, "contoursClip")     except:         print "clipped contours file already exists"                    #Slice the raster data into a range of values of equal interval zones         # Execute Slice tool     outSlice = Slice("outNatNei", numberZones, "EQUAL_INTERVAL")         # Save the output     try:         outSlice.save("dec2009Slice")     except:         print "the slice file already exists"          #Clip sliced raster data to defined boundary around OKX CWA         # Execute raster Clip tool     try:         arcpy.Clip_management("dec2009Slice", "-74.79081276 40.47313532 -71.74223316 41.73718052", \                               "clipOKX", OKX, "", "ClippingGeometry")     except:         print "Clip raster to OKX CWA boundary failed."          # Check in the ArcGIS Spatial Analyst extension license     arcpy.CheckInExtension("Spatial")               #Apply symbology          # Make feature layer for contours save it and apply symbology layer     #try:     arcpy.MakeFeatureLayer_management("contoursClip", "contoursClipLayer")     **arcpy.SaveToLayerFile_management("contoursClipLayer", contoursClipLyr)**     arcpy.ApplySymbologyFromLayer_management("contoursClipLayer", contoursSymb)          #except:         #print "make feature layer/apply symbology for contours failed."          # Apply label to contours     #try:     arcpy.ContourAnnotation_cartography (contoursClipLyr, gdb, "Contour", \                                             "2000000", contourLabel)     arcpy.SaveToLayerFile_management(contourLabel, contourLabelText)     #except:         #print "apply labels to contours failed."          # Make feature layer for raster dataset save it and apply symbology layer     try:         arcpy.MakeRasterLayer_management("clipOKX", "clipOKXLayer")         arcpy.SaveToLayerFile_management("clipOKXLayer", clipOKXLyr)         arcpy.ApplySymbologyFromLayer_management("clipOKXLayer", rasterSymb)          except:         print "make feature layer/apply symbology for raster failed."          #Add layers into map document     addLayer = arcpy.mapping.Layer(OKXcounties)     addLayer1 = arcpy.mapping.Layer(contourLabelText)     addLayer2 = arcpy.mapping.Layer(contoursClipLyr)     addLayer3 = arcpy.mapping.Layer(clipOKXLyr)     arcpy.mapping.AddLayer(df, addLayer, "AUTO_ARRANGE")     arcpy.mapping.AddLayer(df, addLayer1, "AUTO_ARRANGE")     arcpy.mapping.AddLayer(df, addLayer2, "AUTO_ARRANGE")     arcpy.mapping.AddLayer(df, addLayer3, "AUTO_ARRANGE")          # Add contour Labels     for lyr in arcpy.mapping.ListLayers(mxd1):         if lyr.name == "contourLabelText":             lyr.showLabels = True         if lyr.name == "Contour Features":             lyr.transparency = 100          for df in arcpy.mapping.ListDataFrames(mxd1):         df.scale = 2000000          #Save to a new map document and clear variable references     mxd1.saveACopy(mxdSave)     del mxd1          print "finished"      ![parameter_properties](http://i.stack.imgur.com/lGy1Z.png)


title: How to embed metadata into a spatialite layer in QGIS?

text: Example usage: I have a spatialite layer which contain my fiber optic cable routes. In that layer there is a column named 'Cable types' with coded integer data: 1 for aerial cable, 2 for underground cable... Now I want to send the spatialite database to a colleague. Is there anyway to preserve the meaning (description) of cable types without having to send the QGIS style file for that layer?


title: Downloading Google Maps municipal geometry

text: When searching for a city on google maps, google is that smart it displays a geometry line on the boundary off the municipal. See this link: http://g.co/maps/23dz5 Is there a place in the google maps api where I can download this geometry?


title: How to extract cell values from a raster file with Idrisi Taiga?

text: I need to convert raster cells into points. I use Idrisi and I need to generate a table containing xy (coordinates) and z (cell value).


title: Why does aggregate polygons consistently error out?

text: I'm using aggregate polygons on a dataset with three large study areas. It did not work. So I split it into separate areas and did it again. Two of the three areas (which were smaller than the third) aggregated correctly. The third I split into municipalities (since it had a few in it) and then aggregated each separately, apart from two, which refused to aggregate. The error message was not forthcoming, it just says "Background processing has encountered a serious error and is unable to continue. And then it allows me to send an error report to ESRI, which I have, though it's been almost innumerous times. So I used grid index features and made a grid over one municipality and then split the data by that grid. I ended up having to do 5 x 5 km grids (making 42 index polygons) because anything bigger would not process properly. That actually sort of worked, except for five of the grids which would not. I tried vainly to do 'multipart to singlepart' which worked for some of them, though in this case, I had to further subdivide each 5x5 grid into 4 more indices. In that case, quite a few actually processed, but there is one or two stubborn grids which will not process at all and produce the same error. I even went into each grid's data and used the editing toolbar to merge some of the polygons together manually, before using aggregate polygons. Has someone else had similar trouble? Are there any workarounds or suggestions? Because I will otherwise have to repeat the process two or three more times (as it is a time-series project). ![A comparison screenshot of a subset of the data](http://i.stack.imgur.com/uygjO.png) **edit:** I tried dissolve and it does sort-of do what we want, though is there any way to add a distance value to it like aggregate polygons has?


title: How to get bounding box coords?

text: How to get coords for NW and SE if we have about 4-5 pixels on the image with assigned latit/longit? I'm working on javascript app which would overlay that image on Google Map then. Thanks.


title: ArcGIS 10.1 Upgrade Geodatabase Check Version

text: Hi I am trying to check the version of filegeodatabase before upgrading to 10.1, I have a list of file geodatabases and some of them are already in 10.1. Can anyone suggest me how to update only those with version less than 10.1? I am using python script to do this: arcpy.UpgradeGDB_management(r"C:\Test\Base.gdb", "PREREQUISITE_CHECK", "UPGRADE")


title: Split 3D line feature at vertices based on slope change

text: I've already asked a question about this subject, but now I think I'm almost getting to the point. I have to split roads in ramps to calculate LS factor (RUSLE - soil erosion) These are the steps that I'm trying to do: 1. Create a DEM using Topo to Raster 2. Convert the roads (polyline features) to 3D features using Interpolate shape (ArcGIS 10.1) 3. Split line at vertices. But now the problem begins... There are too many vertices in each polyline, is there a way to "clean" these vertices leaving only the ones where the slope abruptly changes (from going up to going down)? Or maybe create points at the Z min and Z max? Or any other ideas? Thank you very much! I hope you understand!


title: Editing vector data over the net: WFS or PostGIS?

text: I'm using QGis to update the attributes of a large vector dataset (~20,000 polygons) stored in PostGIS. I'm going to have to do that to other large datasets so the idea is to bring in more people, each editing a separate table (no concurrent editing). I'm wondering what would be the best option: Have the users connect directly to PostGIS and edit the data? Or publish the data in GeoServer and use WFS? Are there any gains in speed if I use WFS (cache, load only polygons in visible window)? Or would the extra layer (geoserver) slow me down? I'm using QGis as a desktop client.


title: Why can't I open a .xls with QGIS in OSX?

text: I'm trying to open an `.xls`with QGIS 1.8 in a Mac, I'm loading the vector layer from `Add new vector layer`etc. etc. the procedure works in Windows but not in Mac where I have an error `Invalid source file`. Where is the problem?


title: GeoWebCache: Is there a way to empty the cache only for a certain zoom level?

text: This is a follow-up to this question. In short, I was overambitious in seeding and now my /usr filesystem is full. Take a look at the cache occupancy broken down by zoom level. (Data is OSM South America slice by Geofabrik, imported by osm2pgsql.)               [root@opengeosa opengeo_southamerica]# du -sk EPSG_900913*     4       EPSG_900913_00     8       EPSG_900913_01     16      EPSG_900913_02     36      EPSG_900913_03     236     EPSG_900913_04     832     EPSG_900913_05     3236    EPSG_900913_06     11088   EPSG_900913_07     32828   EPSG_900913_08     110464  EPSG_900913_09     392380  EPSG_900913_10     1487876 EPSG_900913_11     5303356 EPSG_900913_12     20030184        EPSG_900913_13     15776620        EPSG_900913_14     8828    EPSG_900913_15     189778220       EPSG_900913_16     7932    EPSG_900913_17     3764    EPSG_900913_18     492     EPSG_900913_19     200     EPSG_900913_20     352     EPSG_900913_21     [root@opengeosa opengeo_southamerica]#       So, I would like to empy the misbegotten level 16 cache and leave all others. Is this doable? Could I just `rm -rf EPSG_900913_16/*` or would that be a Very Bad Thing™? Or should I just empty the entire cache and reseed only through level 14?


title: Get displaylevels/zoom level javascript API

text: Is there any way using JavaScript API to get the current "displayLevels" of the basemap or "basemap zoom level" or "basemap scale" of the map and if it was more/less than certain number I change the Layer to another layer?               function(             Map,             FeatureLayer             ){          map = new Map("map", {                basemap: "topo",                center: [-85.416, 49.781],                zoom : 5,                logo: false});     if (map zoom level == ***) {           layer1 = new FeatureLayer(                     "http://testServer/arcgis/rest/services/test/MapServer/0", {                             mode: FeatureLayer.MODE_ONDEMAND                             });                  map.addLayer(layer1);     }          else {     layer2 = new FeatureLayer(                     "http://testServer/arcgis/rest/services/test/MapServer/1", {                             mode: FeatureLayer.MODE_ONDEMAND                             });                  map.addLayer(layer2);          }


title: WFS Layer error

text: I get this error with 1.7.*-Wrowclaw   _**Error downloadinghttp://www.igmi.org/wfs_server? SERVICE=WFS&REQUEST=GetCapabilities&VERSION=1.0.0 - server replied: Bad Request_**   can i resolve localy or is necessary work on server?   thanks


title: How to port QGIS C++ plugins to other QGIS installations?

text: I developed a C++ plugin for QGIS using VC++ express 2008 and a QGIS dev release (1.9.90 alpha), my plugin works fine on this release and now I want to port it to other QGIS installations, so I copied the generated dll to the plugins directory of a QGIS 1.7.4 installation but it didn't get recognized by the extension manager. Anybody can help with this? Thx!


title: High Mountain hillshade is not "natural"

text: after generalizing my DHM and extraction of different color-hillshades, I got something like this: ![experimental_hillshade](http://i.stack.imgur.com/6d1Eq.png) Its not very good, but I used the idea of Imhof generalizing and coloring the hillshade (multishade). Its "digital-round-smooth" like "organic" and not "natural-edged-hard" like I want it to. (Sorry for that kind of english :) I mean, in natural its a very steep and hard mountain range, and not a hilly "hobbit-land" :) Do you have any Idea, how to construct it more natural? Thanks! Martin


title: Filegeodatabase fanout

text: I tried to fanout data but it is all in the same FGDB. So, is it possible to do this? I need to write data for every time different amount of different area into different, but schematic same filegeodatabse. Best regards.


title: How to automatically plot intermediate contours with QGIS, GRASS GIS or SAGA GIS?

text: I'm mapping a steep mountain range. My main contour interval is 50 m and my intermediate contour interval is 10 m. In steep areas, the interval of 10 m is too small, so I need to leave of the 10 m-interval and use 20 m or 25 m instead. Is there a way, to do that automated in QGIS, SAGA GIS or GRASS GIS?


title: Expression does not evaluate to column or table name?

text: This is my code:               Include "MAPBASIC.DEF"     Include   "MENU.DEF"          Dim s_filename As String     s_filename = FileOpenDlg("","","TAB"," Open Table Interactive")      Browse * From s_filename       I want to open a file from my computer.


title: Rotating annotation by angle using center point of annotations (with baseline alignment) in ArcMap

text: Is it possible to rotate annotation (in ESRI Annotation FeatureClass) by angle so that new position would be calculated based on annotation center point (not alignment, as it is set to baseline, center)? OR alternatively- would it be possible to change annotation alignment to center/center without moving annotation? I have thousands of annotations and I would like to update their rotation based on updated angle field in database. All annotations have VERTICALALIGNMENT set to “baseline”.


title: ST_Within for TIN or 3D objct in PostGIS

text: I would like to query if a point is located in the TIN object. My TIN object is closed (convex hull) object (i.e. surface of a round object). I tried to use `ST_Within`, but the error message returns as: > ERROR: Unknown geometry type: 15 - Tin My query is as follows:               SELECT ST_Within(mypoint,mytinobject) As mypointinmytinobject     FROM     (SELECT ST_GeomFromText('POINT(x,y,z)', SRID) As mypoint,     (SELECT geom FROM mytintable WHERE gid=1) As mytinobject     ) As myobjects;      What are the equivalent 3D query functions like `ST_Within` for 3D TIN object in PostGIS? It is a complex 3D anatomical region. It is not solid, it is a surface. If it is represented as Polyhedralsurface, how could we query if a point is located inside this closed surface (or a region). Do I need to make it solid body. Could it be done in PostGIS?


title: Python Label Expression: Only show text after a particular symbol

text: I have a bunch of point data that needs labeling. However the attribute used for labeling is more complex than is needed in the map. Example of the attribute field for labeling:   * 15/8-9a,    * 001/15-2   * 8/19-13 What we need to see labeled is any number and/or letter found after the "-" symbol. So from the above example: **9a, 2, 13** will be displayed on the map. I know this can be done with slicing but since the number of characters after "-" is variable I'm struggling a little with the expression. I do not want to add a new field so am exploring writing a label expression. Does anyone know what the expression might look like to handle this?


title: editor tracking updated in attribute table, but not in sql server database

text: When I enable editor tracking and make modification on an object, I can find the edit user and edit time, but I cannot find the data updated in the sql server database. Is it because of the versioning? If yes when will the data updated in the sql server database? If no, what is wrong with my sql server database? The following pictures are attribute table in ArcMap and table value in sql server. ![enter image description here](http://i.stack.imgur.com/1vcFx.jpg) ![enter image description here](http://i.stack.imgur.com/KayAO.png) I am using ArcMap 10.2.2 and sql server 2008 r2.


title: QGIS Projections

text: I am new to the GIS world and have faired pretty well with ArcGIS 9.3, learned and still learning on the job. I would like to get a better handle on QGIS though. I linked the files from my dropbox. I tried the on the fly projection and changing the projection of the following file: http://db.tt/Nuc9Bni4 I need the aforementioned file to project and line up with the following boundry file: http://db.tt/Ij6MEyDz Thanks in advacnce for any input.


title: How does TomTom store trackpoint information on its internal drive?

text: How does TomTom stores tracks and trackpoints on its internal drive? I maintain an open source computer forensics tool and would like to extract the data from both files and unallocated space. My experience with Garmin GPS devices is that they all use the same internal data format, and I suspect that TomTom devices do the same.


title: Display Access query in ArcMap

text: Hi I have an access database and have some built in queries in the database. The same data is stored in geodatabase with the spatial information. Now I want to follow this process: Access->push out query->open arcmap mxd ->display results. Is there a way to do this? I am using MS access 2010 and ArcGIS 10.1. Any help on this is most welcome. Thanks


title: problem adding pop-up to GeoJSON layer in Leaflet

text: I'm new to working with the Leaflet API and am running into trouble with creating popups for a GeoJSON layer. I've looked at the following post as a reference and am still having difficulty: binding nested arrays as geojson popups in leaflet My GeoJson data looks like:               {         "type": "FeatureCollection",         "features": [             {                 "geometry": {                     "type": "Point",                     "coordinates": [                         -73.97364044189453,                         40.66893768310547                     ]                 },                 "type": "Feature",                 "properties": {                     "lon": -73.97364044189453,                     "lat": 40.66893768310547,                     "version": "1.1",                     "t": 1381167616,                     "device": "iPhone3,3",                     "alt": 67,                     "os": "6.1.3"                 }             },             {                 "geometry": {                     "type": "Point",                     "coordinates": [                         -73.96121215820312,                         40.66240692138672                     ]                 },                 "type": "Feature",                 "properties": {                     "lon": -73.96121215820312,                     "lat": 40.66240692138672,                     "version": "1.1",                     "t": 1381171200,                     "device": "iPhone3,3",                     "alt": 45,                     "os": "6.1.3"                 }             }              ]     }      My leaflet js is as follows:               // create a variable to load Stamen 'toner' tiles     var layer = new L.StamenTileLayer("toner");          // initialize and set map center and zoom     var map = L.map('map', {         center: new L.LatLng(40.67, -73.94),         zoom: 12     });          // create the map      map.addLayer(layer);          // on each feature use feature data to create a pop-up     function onEachFeature(feature, layer) {              if (feature.properties) {                  var popupContent;             popupContent = feature.properties.t;                  console.log(popupContent);             }         layer.bindPopup(popupContent);     }          // grab the processed GeoJSON through ajax call     var geojsonFeature = (function() {             var json = null;             $.ajax({                 'async': false,                 'global': false,                 'url': "/data/test_random.json",                 'dataType': "json",                 'success': function (data) {                     json = data;                 }             });             return json;         })();          // create an object to store marker style properties     var geojsonMarkerOptions = {         radius: 10,         fillColor: "rgb(255,0,195)",         color: "#000",         weight: 0,         opacity: 1,         fillOpacity: 1     };          // load the geojson to the map with marker styling     L.geoJson(geojsonFeature, {              style: function (feature) {             return feature.properties && feature.properties.style;         },              onEachFeature: onEachFeature,              pointToLayer: function (feature, latlng) {             return L.circleMarker(latlng, geojsonMarkerOptions)         }     }).addTo(map);      The `console.log(popupContent);` call within the `onEachFeature` function is returning data, however when I click on the GeoJSON points in the map I get the following error: `Uncaught NotFoundError: An attempt was made to reference a Node in a context where it does not exist.` I've tried looking into this with no success so far. Any advice would be appreciated, thank you.


title: Selecting a suitable GIS for my project

text: I need to develop a web-based map using existing shape files. Using the web- map, we must be able to select a region and produce contours for that selected region. Can any one suggest the best open source solutions for this?


title: Merge multiple linestring features into a single multilinestring

text: Using QGis or ogr2ogr how do I convert a vector file containing multiple linestrings features into a single multilinestring feature? At the moment I've been doing this manually by converting the data to GeoJson and editing it manually.


title: How to troubleshoot a slow IIS and hanging ArcGIS Server?

text: Our ArcGIS Server 10.0 SP 4 website has been hanging lately where everything gets delivered except the map. When I try and check the REST Endpoints they it hangs and then fails. When I stop the IIS, that takes 2-3 minutes to stop, which is not normal. Sometimes it takes 2 or 3 stop/starts of IIS to get the server back working again. I've made sure ArcGISWebServices is in Admin group as well as all necessary server groups. I looked in the system log for the latest crash and it reads: > @ 8:18 AM "A worker process with process id of '13516' serving application > pool 'ArcGISApplicationsAppPool' has requested a recycle because the worker > process reached its allowed processing time limit. > > @8:30 (approx when I began investigating the issue) "A worker process '7616' > serving application pool 'ArcGISApplicationsAppPool' failed to stop a > listener channel for protocol 'http' in the allotted time. The data field > contains the error number." Any ideas on what I can do to further troubleshoot are appreciated. Specs. WinServer 2008 IIS 7 AGS 10 SP4


title: python qgis.core import error caused by spatialite libraries

text: I have an error when trying to import qgis.core to python:               >>> import qgis.core     Traceback (most recent call last):       File "<stdin>", line 1, in <module>     ImportError: /usr/lib64/libspatialite.so.2: undefined symbol: GEOSBufferParams_destroy      Also DB Manager in QGIS can't work with spatialite due to this error: "/usr/local/lib64/pyton2.7/site-packages/pyspatialite/_spatialite.so: undefined symbol: GEOSSimplify" pyspatialite seems to work fine:               >>> from pysqlite2 import test     >>> test.test()     .....................................................................................................................................................................................................................     ----------------------------------------------------------------------     Ran 213 tests in 2.892s          OK      The issue arose after updating QGIS from 1.7 to 1.8, where pyspatialite (and some other packages) is no longer provided within QGIS. I searched the web but wasn't able to find sollution. Any idea on how to fix it? OS: openSUSE 12.1; python 2.7.2-7.17.1; QGIS 1.8.0-7.2; spatialite 3.0.1-9.1; GEOS 3.3.5-1.1; pyspatialite 3.0.1.


title: How to resize a point on zoom out?

text: I've added a point on map like this but it is static in size. How to resize that point on zooming? Map on zoom out ![enter image description here](http://i.stack.imgur.com/oxpNp.png) Any guidance and help is appreciated.


title: How to calculate new point coordinates from distance and angle?

text: I want to calculate the coordinates of a new point. What I have: The source point coordinates, the distance (meters) and the angle For example: I want to create a point within 100 meters and 45 degree from my source point I use wgs84 as coordinate system. My question now is if it's possible to calculate a new point with the given attributes above and when its possible how I can do that. Kind regards


title: Need to create custom map based the spatial Database

text: I need to create a custom map in .net 2008 c# webapplication based the spatial database(sqlserver 2008) without using any third party tools For example in sqlserver 2008 i am create a map using this SQLCode               declare @ll geometry     set @ll= geometry:: STGeomFromText('LINESTRING (80.2341763 13.0521737, 80.2340631 13.051794, 80.2340366 13.0516397, 80.2338632 13.0508963, 80.2337334 13.0503032, 80.2336701 13.0500048, 80.2335762 13.0496237, 80.2335511 13.0495047, 80.2334451 13.0490013, 80.2332654 13.0482409, 80.2332448 13.048186, 80.233076 13.0473876, 80.2329141 13.0465558, 80.2327947 13.0459422, 80.2327233 13.0455756, 80.2326847 13.0453771, 80.2326169 13.045029, 80.2325305 13.0445849, 80.2325185 13.0445234, 80.2324469 13.0439813, 80.2324085 13.0435336, 80.2324161 13.0432134)',4326)     select @ll as Geometry       after this excution in sqlserver2008 its display the some image , i want same image display in .net webapplication . Please any one help in this process


title: Multiple Country Codes? - World Geocoding Service (ArcGIS REST API)

text: Using single field geocoding, (ArcGIS REST API) I am having an issue with the World Geocoding Service when it comes to getting results that include both USA and US territories, like Puerto Rico for example. Code: `http://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/findAddressCandidates?find=puerto rico&SingleLine=puerto rico&sourceCountry=USA&f=json&outFields=Loc_name&callback=esriDojo.io.script.jsonp_esriDojoIoScript10._jsonpCallback` In the geocode request string above, I am limiting results to USA only ('sourceCountry=USA'), however I get a result that doesn't include Puerto Rico (the commonwealth) - only Puerto Rico, Texas. This is the same if I change my search parameter to "San Juan" - I would like to get San Juan, PR as a result, along with the rest of the 'San Juan' location in CONUS. Esri Help states that you can limit the 'sourceCountry' parameter to "USA" for only results in the US, but problematically this means CONUS, not Puerto Rico or other "US" territories like Virgin islands, Mariana Islands, etc. Esri also has a specific country code geocode limiter for Puerto Rico (PRI) however I cannot find a way to combine this with (USA) into one request which would limit return results to only USA, PRI together. It seems to allow one country code per request, currently. Since this is a web map focused solely on USA and territories, with full extent set to CONUS (including PR and Hawaii), it doesn't make sense for me to remove the 'sourceCounty' parameter altogether. We don't want international results to come up (and they will) since the results are typically ordered by total population. Can anyone recommend a different approach (or updated geocode string) to limiting the results to only USA and Puerto Rico? Is there a way to combine multiple 'sourceCountry" parameters to account for USA & PRI into one geocode request? Thanks in advance


title: How to customize Directions widget of ArcGIS Viewer for Flex 3.4 using Flash Builder 4.6?

text: I want to customize the Directions widget in order to be suitable for my application. However, I do not know how to show a Directions widget without signing in to resources in http://www.arcgis.com. Is this possible to do?


title: Unable to select FLOAT precision when adding column

text: I'm trying to do the lessons in the training-manual at qgis.org. I,m having some problems with 3.3 Ratio Classification http://www.qgis.org/en/docs/training_manual/vector_classification/classification.html according to the training-manual its supposed to look like this![image1](http://i.stack.imgur.com/lXJQ9.png) but mine look like this ![image 2](http://i.stack.imgur.com/H0TSS.png) I am unable to select precision and width of FLOAT. I'm using QGIS 2.2 Valmiera on an iMac. Please exude my bad english.


title: Adding shp files to PostGIS in QGIS 2

text: I followed this tutorial to set up Postgresql 9.1 and PostGIS 2 on my Ubuntu Server 12.04. I also installed pgAdmin III on my Windows 7 client. I set up a database landarch and user chadmwade, granting all privleges. I am able to connect to the postgres and the landarch databases with pgAdmin III and in QGIS. I am getting the following error when attempting up add this shp file to the database. Is someone able to guide me in addressing this error? I haven't had much luck with Google. ![this](http://i.stack.imgur.com/8iEnX.png)


title: Join Issue with Attributes Table

text: I am trying to Join a Mineral Database (excel) into my Attributes table. Once I do and check the Attributes, it shows up as "NULL". What is causing that, what am I not doing? Can anyone offer suggestions/ideas as I am trying to link the .shp to that Mineral excel/database. Thank You, Zoran


title: How would you use change the projection within KML file?

text: I have created some KML files by converting the projection with both ARC and MapWindow. I'm looking for ways to automate exporting the data from our application with coordinates in State Plane "ESRI:102272" to something that can be used in Google Earth. While I'm not a GIS Pro or a Web Developer, I know just enough to export and create maps. I'm looking to create some kml files to share on our webserver. Can proj4js be used to convert the coordinates within the file? Any thoughts on this process would be greatly appreciated.


title: OSM Map projection doesn't seem to change

text: I have the following OpenLayers map:               Proj4js.defs["EPSG:31258"] = "+proj=tmerc +lat_0=0 +lon_0=13.33333333333333 +k=1 +x_0=450000 +y_0=-5000000 +ellps=bessel +towgs84=577.326,90.129,463.919,5.137,1.474,5.297,2.4232 +units=m +no_defs";     var googleProj = new OpenLayers.Projection("EPSG:900913");     var salzburgProj = new OpenLayers.Projection("EPSG:31258");     var bounds = new OpenLayers.Bounds(426249,294999,426251,295001);     var maxZoom = 19;     var minZoom = 15;     var res = [4.77731426696777,2.38865713348389,1.194328566741945,0.5971642833709725];          mapCOD = new OpenLayers.Map({         div: "mapCODs",         allOverlays: true,         maxExtent: bounds,         projection: salzburgProj,         allowSelection: true,         controls: [new OpenLayers.Control.PanZoomBar(), new OpenLayers.Control.Navigation()]     });          var layer = new OpenLayers.Layer.OSM(             "layer1",             "tiles/input/${z}/${x}/${y}.png",             {zoomLevels: maxZoom, zoomOffset: minZoom, resolutions: res}         );               mapCOD.addLayer(layer);      I have produced tiles with mapnik using EPSG:31258, so I would like to change the default projection of the map from 900913 to 31258. The problem is that "projection" parameter is not taken into account and if I perform a `console.log(mapCOD.getProjection())`, I obtain "EPSG:900913". Another proof that map projection remains 900913 is that I have to perform a coversion to get the correct map center:               var center = bounds.getCenterLonLat();     mapCOD.setCenter(center.transform(salzburgProj,googleProj), minZoom);      What am I missing?


title: How to clip a Oracle query layer directly in a Python script?

text: I have a query layer directly running from ORACLE database in a MXD. I want to clip this layer with a layer being created in another MXD in a Python based tool. My question is to do this clip analysis, do I have to make a layer of this query layer locally or I can clip it directly from the query layer? I have success doing it with `MakeFeatureLayer_management` but then creating a layer of 6-7 million records every time this tool runs does not appear efficient and fails the whole purpose of creating query layer. SDE was never implemented for this project and setup was done before I joined the project. Alternatively I tried to run the model in query layer MXD but it will work stand alone and results in error with Python.


title: How do you write a Python script for repairing data sources in ArcGIS 10

text: So, I have about 50 mxd's with all broken layers that I have been going through and manually resetting. The data was moved from another computer and the folder structure was changed so it isn't just a simple process of changing (example): "F:\Data\Rivers.shp" to "C:\Data\Rivers.shp" it is more like : "F:\Data\Rivers.shp" to C:\Data\Park\Water\Rivers.shp and so on for all kinds of data (boundaries, veg cover, roads, etc.) each in their own sub-folder. I wanted to make a script that I could run repeatedly whenever I opened one of these mxd's that would at least repair some of the more common layers that are found in most of my mxd's, and then I could manually repair the rest. That way I at least save myself _some_ time. I have been using something along the lines of :               import arcpy     mxd = arcpy.mapping.MapDocument("CURRENT")          for lyr in arcpy.mapping.ListLayers(mxd):         if lyr == "Rivers": #Should this be the layner name in TOC or FC name?             lyr.replaceDataSource(r"C:\Data\Park\Water", "SHAPEFILE_WORKSPACE", "Rivers")      The idea then would be to somehow add multiple "replace" scripts in the above for other common layers that are in my mxd's. However the above script doesn't even fix the Rivers layer. How can I get it to work, and also add in other layers to be repaired that have different file paths? Sorry, I am a total novice at this stuff and I am probably going about it all wrong. Thanks.


title: How to upgrade PostGIS in OSGEO-Live Xubuntu virtual machine?

text: I have downlaoded the OSGEO-Live 6.0 virtual machine running Linux Xubuntu. I have it running through VirtualBox on a Windows machine. It currently comes preinstalled with a lot of GIS software, including PostGIS 1.5. I would like to upgrade PostGIS to 2.x. Having not used linux much, what is the best method to upgrade PostGIS from 1.5 to 2.x on the Xubuntu virtual machine? Since I just downloaded the Live- DVD, we can assume there is no data that needs to be retained.


title: Use psycopg2 to do loop in postgresql

text: I use postgresql 8.4 to route a river network, and I want to use psycopg2 to loop through all data points in my river network.               #set up python and postgresql connection     import psycopg2          query = """         select *         from driving_distance ($$             select                 gid as id,                 start_id::int4 as source,                 end_id::int4 as target,                 shape_leng::double precision as cost             from network             $$, %s, %s, %s, %s         )     ;"""               conn = psycopg2.connect("dbname = 'routing_template' user = 'postgres' host = 'localhost' password = '****'")     cur = conn.cursor()     while True:         i = 1         if i <= 2:             cur.execute(query, (i, 1000000, False, False))             i = i + 1         else:             break     rs = cur.fetchall()     conn.close()     print rs      The code above costs a lot of time to run even though I have set the maximum iterator i equals to 2, and the output is an error message contains garbage, ![enter image description here](http://i.stack.imgur.com/zZLhU.png) I am thinking that if postgresql can accept only one result at one time, so I tried to put this line in my loop,               rs(i) = cur.fetchall()      and the error message said that this line has bugs, ![enter image description here](http://i.stack.imgur.com/IVU23.png) I know that I can't write code like **rs(i)** , but I don't know the replacement to validate my assumption. So should I save one result to a file first then use the next iterator to run the loop, and again and again? I am working with postgresql 8.4, python 2.7.6 under Windows 8.1 x64. * * * **Update#1** I can do loop using the code below, and the result follows,               import sys     import psycopg2          query = """         select *         from driving_distance ($$             select                 gid as id,                 start_id::int4 as source,                 end_id::int4 as target,                 shape_leng::double precision as cost             from network             $$, %s, %s, %s, %s         )     ;"""               conn = psycopg2.connect("dbname = 'routing_template' user = 'postgres' host = 'localhost' password = '****'")     cur = conn.cursor()          rs = []     i = 1     while i <= k:         cur.execute(query, (i, 1000000, False, False))         rs.append(cur.fetchall())         i = i + 1          for record in rs:         print record          conn.close()               [(1, 2, 0.0), (2, 2, 4729.33082850235), (3, 19, 4874.27571718902), (4, 3, 7397.215962901), (5, 4,      6640.31749097187), (6, 7, 10285.3869655786), (7, 7, 14376.1087618696), (8, 5, 15053.164236979), (9, 10, 16243.5973710466), (10, 8, 19307.3024368889), (11, 9, 21654.8669532788), (12, 11, 23522.6224229233), (13, 18, 29706.6964721152), (14, 21, 24034.6792693279), (15, 18, 25408.306370489), (16, 20, 34204.1769580924), (17, 11, 26465.8348728118), (18, 20, 38596.7313209197), (19, 13, 35184.9925532175), (20, 16, 36530.059646027), (21, 15, 35789.4069722436), (22, 15, 38168.1750567026)]     [(1, 2, 4729.33082850235), (2, 2, 0.0), (3, 19, 144.944888686669), (4, 3, 2667.88513439865), (5, 4, 1910.98666246952), (6, 7, 5556.05613707624), (7, 7, 9646.77793336723), (8, 5, 10323.8334084767), (9, 10, 11514.2665425442), (10, 8, 14577.9716083866), (11, 9, 16925.5361247765), (12, 11, 18793.2915944209), (13, 18, 24977.3656436129), (14, 21, 19305.3484408255), (15, 18, 20678.9755419867), (16, 20, 29474.8461295901), (17, 11, 21736.5040443094), (18, 20, 33867.4004924174), (19, 13, 30455.6617247151), (20, 16, 31800.7288175247), (21, 15, 31060.0761437413), (22, 15, 33438.8442282003)]      but if I want to get this look of output,               (1, 2, 7397.215962901)     (2, 2, 2667.88513439865)     (3, 19, 2522.94024571198)     (4, 3, 0.0)     (5, 4, 4288.98201949483)     (6, 7, 7934.05149410155)     (7, 7, 12024.7732903925)     (8, 5, 12701.828765502)     (9, 10, 13892.2618995696)     (10, 8, 16955.9669654119)     (11, 9, 19303.5314818018)     (12, 11, 21171.2869514462)     (13, 18, 27355.3610006382)     (14, 21, 21683.3437978508)     (15, 18, 23056.970899012)     (16, 20, 31852.8414866154)     (17, 11, 24114.4994013347)     (18, 20, 36245.3958494427)     (19, 13, 32833.6570817404)     (20, 16, 34178.72417455)     (21, 15, 33438.0715007666)     (22, 15, 35816.8395852256)      What should I make a little change in the code？


title: Problem with WMS layer from SAGIS: Invalid format/can't parse XML

text: Can you help me the following problem: I try to load WMS layer from SAGIS (Salzburg GIS) into Qgis: http://www.salzburg.gv.at/themen/se/sagis/download.htm for example: Geoland WMS               http://service.salzburg.gv.at/ArcGIS/services/Geoland_WMS_Land_Salzburg/MapServer/WMSServer      added "?version=1.1.1" to the url connect The dirctory of the availble layers appers ID-0 - layers ID-1 - Polygondecker ID-3 - Orientierunskarte and so on till ID-41 - Landesgrenzen chose the first directory: 0 - Layers (or any other, does not matter) click "connect" (Hinzufügen) following report appears:               Antwort: (<)?xml version="1.0" encoding="UTF-8" standalone="yes" ?>     (<)!DOCTYPE ServiceExceptionReport SYSTEM "http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd">      (<)ServiceExceptionReport version="1.1.1">      (<)ServiceException code="InvalidFormat">     Can't parse XML request.      (<)/ServiceException>     (<)/ServiceExceptionReport>      edit: When I add the suggestion from Brad: ?request=getcapabilities&service=WMS&version=1.1.1& still the same message as above appears I expect to see the chosen layers, but i can only see it in the layer dialog. whenever doing a click on the layers (e.g. zoom to selected layer) the same error message as above appears. Thanks a lot.


title: how activate qgis features selection toolbar in the main window

text: How can i activate and desactivate qgis features selection toolbar in the main window using a signal in a python plugin?


title: How to speed up osm2po when using as java lib?

text: I'am trying to utilize osm2po as java lib for calculation of distances matrix between some set of points (lat/lon) and for each pair of points I call the following method that code is based on sample provided at osm2po.de web-site:               public int getDistance(GeoPoint source, GeoPoint target) {             int res = Integer.MAX_VALUE;             int sourceId = graph.findClosestVertexId(source.getLatitude(), source.getLongitude(), 1);             int targetId = graph.findClosestVertexId(target.getLatitude(), target.getLongitude(), 1);                  router.traverse(graph, sourceId, targetId, Float.MAX_VALUE, params);                  if (router.isVisited(targetId)) { // Found!                 int[] path = router.makePath(targetId);                 float distKm = 0.0f;                      for (int segmentId : path) {                     RoutingResultSegment rrs = graph.lookupSegment(segmentId);                     distKm = distKm + rrs.getKm();                 }                      res = (int)(distKm * 1000);             }                  router.reset();             return res;      But I noticed that it takes about 2-3 seconds per one point to calculate whole distance matrix (I have 10-25 points per matrix in average) that looks not too fast (30-60secs per matrix). Could someone advice what could be improved here - especially I am not sure in correct usage of reset() call - when actually it should be done? - it's not too much documentation on osm2po usage within java...   Also I would appreciate any performance tips to improve this code. One more guess I have is that findClosestVertexId() is expensive enough call and cashing its results for subsequent calls could improve the situation.


title: How to change the case of input text (xtype: "textfield")

text: I have an input box which asks users to input a UK postcode but which specifies that this must be in lower case, for example so16 0as. Some users find this frustrating as they would just like to copy and paste a post code into the textfield; the copied postcode may contain upper case letters ie SO16 0AS. This will return an error. The input code is as follows:               items: [{                 xtype: "textfield",                 width: 220,                 name: "search_lc",                 value: "",                 emptyText:'Enter Postcode (e.g. so16 0as)',                 fieldLabel: "Find",                 allowblank: false             }],      I have tried to use **fieldStyle: 'text-transform:lowercase'** both below the fieldLabel and above it but this doesn't work. I'mm thinking that this should be a fairly simple thing to resolve but I am experiencing a 'can't see the wood for the trees moment'! Any help gratefully received! Many thanks, Red.


title: How to label adjacent pages in data driven pages

text: I'm trying to create a mapbook using `ArcGIS 10.1` data driven pages. Its quite large and I want to create match lines or labels so that if you are looking at a page, there is text/labels showing you which page is adjacent to the top, bottom, left, right. If I remember, correctly, this option was part of the data driven pages toolbar in 10.0, but it doesn't seem to be there now?


title: How to create polygons from a polyline graticule?

text: I'd like to make a polygon shapefile out of a polyline shapefile showing a graticule. However, using the "Line to Polygon" tool results in a peculiar...something: ![enter image description here](http://i.stack.imgur.com/UXuiD.jpg) Other standard tools like "Buffer" etc. seem to work just fine with the polyline shapefile. Anyone experienced this before? Edit: I've just added another latitude to close the graticule and then used "Polygonize". It reached 50% and then crashed: ![enter image description here](http://i.imgur.com/VIfbv05.jpg) The log says: "Uncaught error while executing algorithm Traceback (most recent call last): Traceback (most recent call last): File "C:/PROGRA~1/QGISVA~1/apps/qgis/./python/plugins\processing\core\GeoAlgorithm.py", line 202, in execute self.processAlgorithm(progress) File "C:/PROGRA~1/QGISVA~1/apps/qgis/./python/plugins\processing\algs\Polygonize.py", line 87, in processAlgorithm total = 50.0 / float(len(polygons)) ZeroDivisionError: float division by zero" If there is something wrong with the original script, what can I do? Edit 2: Using "Polygonize" with the cleaned vector layer resulting from "v.clean" gives me the following as a result: ![enter image description here](http://i.imgur.com/1NOHC4z.jpg) The "v.clean" error layer is completely blank. Which tool should I use in order to split the resulting lines from "v.clean" at each intersection with another line?


title: r.sim.water G_malloc error

text: I've been trying to run r.sim.water on a 3 meter LiDAR-generated DEM I have, but keep getting G_malloc errors:               r.sim.water --verbose elevin=meterDEM.final@Sediment_Simulation dxin=centDEM.dx@Sediment_Simulation dyin=centDEM.dy@Sediment_Simulation depth=sim.water.depth disch=sim.water.discharge err=sim.water.error nwalk=1000      My error message:               ERROR: G_malloc: unable to allocate 43608 bytes at main.c:488      I'm running GRASS 6.4.2 on Windows. I've tried using a Ubuntu install on VirtualBox, and it fails out without any error at all. I tried ratcheting down the number of walkers (hence nwalk=1000), but that doesn't seem to help. I can't really think of what to try next.


title: How to maintain schema when copying feature from layer 1 to layer 2, where both layers have same schema?

text: If I load two unique layers, wherein each layer contains unique data, but both layers share the exact same schema, why is it when I copy a feature from layer 1, and paste it into layer 2, the attributes to not transfer exactly as they should? What happens is when pasting a feature from layer 1 into layer 2, the layer 2 attributes of said feature has the data offset by 2 columns, e.g.- > layer 1 schema   >  id   >  clave   >  name   >  address   >  tel * * * > layer 2 schema   >  id   >  clave   >  name   >  address   >  tel A record from layer 1 like this:   > clave; 666   >  name; JOE BLOW   >  address; 123 ANYSTREET   >  tel: 867-5309   >  email; joe@blow.com Transfers to layer 2 like this:   > clave;   >  name;   >  address; 666   >  tel: JOE BLOW   >  email; 123 ANYSTREET So, the actual data is being offset by two columns, and the two columns that are passed over, the data from those columns does not show up anywhere. Clearly, this is not the way it should be behaving, perhaps others have had the same problem? Thanks, Eric Jarvies


title: How to add polygon in MySQL database

text: I have a table which contains an field `zoneShape` of the type `Polygon`. When inserting some geometry in this field, in phpmyadmin it says: affected 1 row. The row is added, but the geometry field says it's size is 0B. Which can't be accurate, cause it has multiple points. This is the Insertion code:               SET @g = 'POLYGON(50.866753 5.686455, 50.859819 5.708942, 50.851475 5.722675, 50.841611 5.720615, 50.834023 5.708427, 50.840744 5.689373, 50.858735 5.673923, 50.866753 5.686455)';     INSERT INTO zone SET zoneShape = PolygonFromText(@g)      As you can see; the first and last point are the same, so the polygon is closed. Can anyone help me with adding this polygon to the database? Thanx


title: MODIS images set CRS and reproject

text: I am developing a plugin which reads MODIS images, and I know that MODIS images are in sinusoidal projection and I need to set that CRS and project the image to WGS84 (epsg 4326) in python. I search and find QgsRasterProjector class but I don't understand how to use this class. Is there another way? I also tried the processing commands but there isn't Assign Projection command in processing, just the warp.


title: Hyperlinking in QGIS - Add Data to current window

text: I am looking to add to my current action in QGIS so that a hyperlinked file will open in the current QGIS window, rather than in a new window. Here is what my action looks like:               "C:/Program Files (x86)/Quantum GIS Wroclaw/apps/qgis/bin/qgis.exe" "C:\Users\Ryan Garnett\Dropbox\SpatialData\Imagery\Landsat\%Image"      I am hoping I can use this as a means to share data so that users can load in satellite images basked on a click with the Hotlinks plugin. Thanks, Ryan * * * Thanks Nathan, I tried this, but it did not load the file. It came back with the following error: C:\Users\Ryan Garnett\Dropbox\SpatialData\Imagery\Landsat8020_nad83_utm_30m_123457.jp2 is not a valid or recognized raster data source This is what I have written in the action: qgis.utils.iface.addRasterLayer("C:\Users\Ryan Garnett\Dropbox\SpatialData\Imagery\Landsat\%Image") With is set to Python. I have noticed in the error that there isn't a \ in between Landsat and the file name, plus the file name has been cut short, from 028020_nad83... to Landsat8020_nad83... Any thoughts? My other way is still working to load it into a new


title: Is it possible to load automatically a customization file in qgis?

text: I have customized QGIS menu and toolbars thanks to the customization option and I have created a configuration.ini file that I can load on several machines. Now, is it possible to create a project and automatically load a specific config.ini file for that project? I didn't found anything in the project properties or in the option menu, but maybe there is another way. BTW: QGIS 2.1 Master with Debian 7.2 Thanks


title: 3d earth mapping with javascript or browser plugin

text: I am currently working to develop a web-based mapping application. A lot of the mapping tools such as google maps are 2d imagery. I know that google earth has a 3d browser plugin, but a requirement of this project as that I need to be able to host my own map server (I know I can with Google Earth, but the enterprise edition is pricey). Are there any good alternatives to a 3d mapping engine for the browser (I've looked into using worldwind for the browser, but that only supports applets for the web)?


title: What is the difference between Astar and Dijkstra algorithms in Pgrouting?

text: I would like to know what is the difference between A* algorithm and Dijkstra at finding the shortest path at pgrouting. Which one is faster ,has better performance and returns better results. Also i would like to know if it is possible for pgrouting to take into account that a road is one way when it computes the shortest path thus not traversing it Sorry for my english thanks in advance john


title: Does SearchCursor reset work in ArcGIS 10.0?

text: In a script I have designed a function that is used multiple times on different search cursors to search through a whole table. Function variables: p - a list of points: actually a list of two-element lists with point coordinates, e.g. [[4710000.0, 3300000.0], [4715000.0, 3305000.0], [4710000.0, 3310000.0], [4705000.0, 3305000.0], [4715000.0, 3300000.0], [4715000.0, 3310000.0], [4705000.0, 3310000.0], [4705000.0, 3300000.0]] c - a SearchCursor on a table with point coordinates The function is supposed to search through the table with a cursor and return a list of points from the table that are also on the "p" list.               def ptsrch(p,c):         list = []         for i in c:             currpt = [i.getValue("X_GRID"),i.getValue("Y_GRID")]             if currpt in p:                 list.append(currpt)         c.reset()         return list      It works fine on the first use of each SearchCursor. Even though at the end of the function the cursor is supposed to reset, it doesn't. In ArcGIS 10 Desktop help reset() is listed as a method: http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//000v00000068000000 I found a worrying post from 2008 on ESRI Forums: http://forums.esri.com/Thread.asp?c=93&f=1729&t=250536 in which it is stated that "As far as I know, the Reset Method has never worked. I was told 2-3 years ago that it would be operational in a "future release". Apparently that time hasn't come yet!" That one though refers to ArcGIS 9.3 or earlier. I have also found a blog post: https://omniolocalia.wordpress.com/tag/arcpy- da-searchcursor/ which praises the possibility to reset cursors in ArcGIS 10.1, mentioning that it was previously impossible. So, has anyone encountered a similar problem? Instead of a SearchCursor I can of course load all tables to Python lists and keep them in memory, though I'm afraid of a memory overload - the total number of rows in these tables will be almost 400000 (right now I'm testing on a small chunk of data, so the total number of rows is 500).


title: Calculating distance and/or time taken to travel from population centre to nearest hospital in QGIS

text: I'm trying to find out how long it would take to travel by car from each of the Lower Layer Super Output Areas (LSOA) in Norfolk, England to the nearest Hospital (or just what the distance is and I can estimate drive time, if the former is too difficult/impossible!). Any suggestions how I can do that using QGIS, OSM road data and/or Ordnance Survey Meridian 2 road data, population weighted centroids for each of the 2011 Census LSOA areas and hospital locations? I have all of the above in QGIS (see image below). There are 537 LSOA and four hospitals in total. Is there a way to work out the time taken and/or distance to travel without having to do it one by one? ![enter image description here](http://i.stack.imgur.com/C4ZNa.jpg)


title: Mapping Tables for Parcel IDs

text: I am working on a residential real estate database in MS ACCESS. I currently have residential property’s tagged by parcel ID’s. I am trying to run a query to pull in multiple sales data from various tables. I need to somehow map in street mapping to only pull data for all property’s within a mile radius. Can anyone explain to me how I can find this mapping? I can program this in access – I just can’t locate the mapping for this project. Thanks, Derrick PS - location - US, Indiana


title: Using line of sight or something similar to identify where lines go through hills

text: When QCing power infrastructure I am having to zoom into every gap and check to make sure the line makes sense (not going through the mountain). I typically check for odd spacing between the pylons and zoom into the imagery. What I want to accomplish is have some tool identify where the 'line of sight' would intersect with the DTED_Level_2. Is there a tool in ArcMap 10.1 that can accomplish this? I have 3D Analyst installed.![View checking the line makes sense](http://i.stack.imgur.com/5qciV.jpg) ![View from google earth](http://i.stack.imgur.com/nrygI.jpg)


title: Esri Android Basemap with kml

text: I created a kml using the kmllayer. When I set the map with a basemap and use the addLayer() method the kml is not shown. I can see the kml layer without a basemap. Can someone post sample code on using basemap with kml? am using ArcGISTiledMapServiceLayer as basemap