New answers tagged

2

While not answering the specific question, I try to aim at the functionality the OP is seeking. I often use these different selection methods myself, and for convenience I have added a dropdown list to my toolbar (and rearranged some of the other buttons): If this is not enough for you, I'd suggest using the built-in system for creating keyboard ...


1

Yo can do selection by both attribute using arcpy.SelectLayerByAttribute_management and location using arcpy.SelectLayerByLocation_management, but you cannot do selection directly from feature, you should create a temporary layer using arcpy.MakeFeatureLayer_management before doing a selection. Here is snippet code from the above help: # Import system ...


2

arcpy.SelectLayerByAttribute_management and arcpy.SelectLAyerByLocation management both have the optional parameter Selection Type. The value must be one of the following strings: "NEW_SELECTION" "ADD_TO_SELECTION" "REMOVE_FROM_SELECTION" "SUBSET_SELECTION" "SWITCH_SELECTION" "CLEAR_SELECTION"


0

Setting the selection method is an option on the Select Layer By Attributes tool. However, I am not sure that a Python AddIn will offer the advantage you seek here.


3

"column1" LIKE concat('%',"column2",'%') OR "column2" LIKE concat('%',"column1",'%') That will search in both ways.


0

For newer Openlayers 3 the array is not kept in the Layer any longer. You can get by the interaction.select itself: //get features as collection var features=interaction_select.getFeatures(); //get length (.length doesnot work in my case) var int_features=features.getLength(); //or access by numeric index like any collection var first_item=features.item(0); ...


0

I've never seen this button anywhere else in QGIS, but I agree that it can be useful. Here is a Workaround (a bit of python...) to achieve what you are after. Presuming you have selected something on a layer and this layer is selected in the layer tree (python speaking: iface.activeLayer()) you can do on the python console: l = iface.activeLayer() l....



Top 50 recent answers are included