Tag Info

Hot answers tagged

6

You can do this by using Layer Groups. In the Admin interface, Under the 'Data' section on the left click on 'Layer Groups'. Then, in the usual GeoServer way, create a new layer group (by default you may already have a couple of examples) and then follow the intuitive interface to add layers to the group. Once you have your Layer Group created, go back ...


6

A SearchCursor in arcpy is the most direct route for accomplishing this: import arcpy fc = "c:/data/base.gdb/roads" field = "StreetName" cursor = arcpy.SearchCursor(fc) row = cursor.next() while row: print(row.getValue(field)) row = cursor.next() Note that you can use the where_clause property to perform your selection.


5

Any file included in the Install\ directory of your add-in project will be carried along in the Python add-in when you run makeaddin.py. You can include layer files or anything else really. You'll find the absolute path to them on disk via path_to_layer = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'mylayer.lyr') in your whatever_addin.py to ...


5

Your downloaded shapefile already had a coordinate system defined in its *.prj file: ...


4

If you have a contour lines layer with associated elevation attribute, you can query the contour lines in reference to the elevation values. More in detail, you could define a rule-based style in Vector properties --> Style in order to query the elevation values you are interested in. For instance, suppose you have contour lines with equidistance 5 m and ...


4

The styles are normally saved in public.layer_styles. Being in the public schema it should be accessible to every user. If not, make sure it becomes using: GRANT SELECT ON TABLE public.layer_styles TO users; -- "users" is a group with all your #normal users


3

The other way is to list all the layers you want in the LAYERS parameter of your WMS request. If you have GeoServer installed locally you can try ...


3

Right click on the layer in table of contents. Select data> repair data source. Then save the layer file again. There could be issues with either your MXD location, or you relative/actual path setting. I use the relative path method but ALWAYS keep my MXD in a folder directly under the data. always keep the mxd file in the folder together Not ...


3

You are very close, just on the wrong tab! Go Settings->Options->Canvas & Legend and set 'Bold group names' to true and 'Bold layer names' to false. You've got a few other options to play with here too (like capitalising the layer names and displaying the classification attribute names), which might be useful for you too.


3

In QGIS 2.01, there is now a checkbox which enables usage of degree-minutes-seconds. Worked for me 2 weeks ago, but at the moment there might be bugs. In general: This coordinate format is a pain and you should get rid of them as soon as possible, cause there are so many different variations, that it is a horror to create new conversions for them all the ...


3

In ArcMap - you could do the following: Select the polygon you want to copy. Open the Python window and type in the following code: cur,row = None, None cur = arcpy.SearchCursor("NAME OF THE LAYER HERE") x = 113 for row in cur: shp = row.getValue("SHAPE") cur,row = None, None cur = arcpy.InsertCursor("NAME OF THE LAYER HERE") for i in range(0,x): ...


3

Your problem is that you have added your data using Postgres data type Point, http://www.postgresql.org/docs/9.3/static/datatype-geometric.html Rather than the PostGIS geometry, or Geography type http://postgis.net/docs/reference.html#PostGIS_Types GeoServer has a PostGIS Data Store connector, rather than a Postgres Data Store connector. Good Luck


3

Try printing to pdf, but set the page size to 24x36 (or a larger sheet of preferred), and make all the font as small as possible (font size 4 or 5). When you print to pdf, keep all of the settings on normal, not high-quality. You should be able to open up the pdf an zoom in and see details. thanks and good luck


3

This is already documented here. There are two undocumented tileerror events for the layer When a single tile is missing it trigger the event “loadwarning” to indicate that something is wrong with this layer. When all the tiles in a layer are missing it trigger the event “loadfail”. There is also some additional documentation in the code here UPDATE ...


3

You can either duplicate the buildings layer, once on the bottom for the polygon, one on top for the symbol, or create symbol labels. Labels are always on top. See Labels | Background | Shape = SVG


3

You will need to use ArcObjects. You are looking for the IDisplayExpressionProperties interface. It is obtained from IDisplayString, which in turn is obtained from IFeatureLayer. Here you will find a fantastic little snippet of code provided by patrick that does the trick: public void annotateLayer(ILayer thisLayer, String geocode, double minScale, double ...


3

I just tested using ArcGIS 10.2.2 for Desktop and my expectation was that highlighting a layer (or layer group) in the Table of Contents would activate the Remove button on the Standard toolbar - but it did not. I also tried the Delete key and Ctrl-X but neither of them allow you to remove a selected layer either. As far as I can tell the only ways to ...


2

Kelso's answer is correct. However, the documentation (and API) is a bit confusing. For example, to create a custom info box, based on this example: http://leafletjs.com/examples/choropleth.html you can do this: var mapInfo = L.control({position:'topleft'}); info.onAdd = function (map) { this._div = L.DomUtil.create('div', 'info'); // create a div with a ...


2

We've recently released some open source software - Open Door Logistics Studio - which lets you perform free territory mapping and free territory design, targeted for the UK. We've also generated, using voronoi etc, postcode areas, districts and sector boundaries for the UK for use in our software - also free. You should be able to just use this directly for ...


2

You can pass params object in the OpenLayers.Protocol.HTTP. See here http://dev.openlayers.org/docs/files/OpenLayers/Protocol/HTTP-js.html#OpenLayers.Protocol.HTTP.params your protocol part of code should look like protocol: new OpenLayers.Protocol.HTTP({ url: EMS_SOURCES_WS, callbackKey: 'callback', ...


2

You can not use degrees-minutes-seconds format in QGIS 1.8.0, only decimal degrees is supported. Calculating decimal degrees in the csv should be easy using Excel. Furthermore, I would advise you not to use file names with non-ASCII-characters like é ó .


2

If you have a layer in degrees, you are using a geodetic coordinate system, like WGS84. If you want meters as units, you have to save the layer into a projected coordinate system, like UTM. So Rightlick on the layer entry, Save As ... , select a new filename and a different CRS, and add that file to the canvas. There is no simple way to change the layer ...


2

The best possible solution for you is to check the logs for your webserver. In our case, we are passing all our requests through Apache, which is functioning as a reverse proxy. We regularly look at Apache's Access Logs and see which of our services are most used, and act accordingly. If your Geoserver is hosted in Tomcat, or Jetty, you can enable the ...


2

There are two approaches that could be used. The first one is more like what you are trying to achieve. Option 1: Layer max extent You can set the maxExtent property for the layer along with the displayOutsideMaxExtent property to prevent OpenLayers from requesting tiles that would fall outside the maximum extent. If you don't specify a maximum extent for ...


2

You may be encountering bug NIM087647 which suggests: Alternate Solution Use the Add Data button in ArcMap to add the table to the table of contents.


2

An interesting question, but I'm afraid it's a non-trivial job. I have some thoughts but not sure if it's the right way to go. So probably you need to use browser's drag-and-drop feature (if it is supported). Create a custom openlayers control that you can drag and drop features between multiple map instances. When starting drag a feature from one map, get ...


2

From QGIS 2 advanced changelog you can read : Feature: Save styles in your database If you are using a database vector data store, you can now store the layer style definitions directly in the database. This makes it easy to share styled layers in an enterprise or multi-user environment. (source : http://changelog.linfiniti.com/version/1/) It ...


2

I'd take a look at example 3, here: Scraping through lyr.serviceProperties what you're looking for. lyr.dataSource on an SDE layer will return the file path to the .sde connection file, which you won't have access to. You should be able to loop through the serviceProperties and get what you need. From the linked ArcGIS Help: for lyr in ...


2

I've converted this to AMD below. Specific things to point out: use require() to load modules instead of dojo.require() no longer use any esri.whatever globals no longer use any dojo.whatever globals dojo/domReady (or dojo/ready) replaces dojo.addOnLoad or dojo.ready use object.on to listen to events, this replaces dojo.connect (example is map.on(), this ...


2

The problem in this case appears to be that the shapefile is projected and that the US map is not. The US map does get displayed, but as a tiny dot in the middle of the other map. If you look at the scale of the axes of the two plots above, you'll see why this would be. The solution was to use a shapefile in the same projection to add an outline.



Only top voted, non community-wiki answers of a minimum length are eligible