Questions tagged [actions]

An action is something that happens when you click on a feature (in QGIS). It can add functionality to a map, such as retrieving additional information about an object.

Filter by
Sorted by
Tagged with
0 votes
1 answer
220 views

QGIS hyperlink to server location- working in 3.0 but not 2.18.20?

This is not necessarily a pressing issue, as there is a workaround, but it has piqued my curiosity about how QGIS manages hyperlinks through its 'Action' functionality. Please feel free to correct my ...
RobinHorner's user avatar
1 vote
1 answer
182 views

QGis 2.18 Actions window does not display 'Actions Properties'

I have installed QGis 2.18.19 64bits in Windows 7. My problem is when I open the layer properties actions window, I do not see the menu Action Properties. Apparently it should be there according to ...
nanunga's user avatar
  • 513
1 vote
1 answer
69 views

Action ran severall times when clicking on overlapping features

I have a layer of points and I associated a Python action to that layer which basically opens a url in the embedded QWebView. This works well. The issue I am facing is that if I zoom out and click ...
ClemRz's user avatar
  • 71
3 votes
1 answer
353 views

Creating link between geopackage and pdf

I'm trying to create a link between geopackage and a folder that contains pdf files. There are points with the same name and they should open the same pdf. I want name 100 to open 100.pdf. Name 101 ...
Flugan's user avatar
  • 51
1 vote
1 answer
306 views

How to make a clickable label in qgis from an excel sheet?

I have location data in excel sheet where each label has corresponding data file for each financial year. I want it that when i click on a label, years pop up, and when i click on that year, its ...
anupam atri's user avatar
2 votes
0 answers
119 views

Action opening DWG file in Intellicad using file name in a attribute table

I have tried numerous variations in creating an action to open a DWG file in Intellicad after selecting a specific row in a table in QGIS. I am quite frankly stumped at this point. I have the DWG ...
jbgramm's user avatar
  • 1,317
3 votes
2 answers
2k views

How to add a new feature to a layer

I have a table with three attributes [field1, field2, field3]. I'm trying to insert a new feature to this table by defining field2 and field3 only. lyr = QgsMapLayerRegistry.instance().mapLayer('...
var29's user avatar
  • 51
1 vote
0 answers
383 views

Get id of last added feature in qgis python action [duplicate]

I created a python qgis action that open the dialog form so the user can add a new feature. maintenance_lyr = QgsMapLayerRegistry.instance().mapLayer('od_maintenance_event20180212171049766') ...
var29's user avatar
  • 51
4 votes
1 answer
4k views

Creating QGIS copy-paste features between two layers using PyQGIS? [duplicate]

i want to create a QGIS action which copies features between two points layers using pyqgis . i have read How to create a QGIS action which copies features between layers? and i try to use this code: ...
hellas's user avatar
  • 363
2 votes
1 answer
389 views

QGIS Action which load .asc

I have a grid layer (lidar_cortina) with "NAME" and "percorso"(path) coloumns: I'm trying to write an QGIS action that loads file .asc from a grid layer. qgis.utils.iface.addRasterLayer("[%percorso%]...
Daniele Piccolo's user avatar
1 vote
0 answers
69 views

Initiate field value before adding new feature

I have two layers: Chambre(obj_id) Ouvrage(obj_id, fk_chambre) The attribute Ouvrage.fk_chambre is referencing the attribute Chambre.obj_id. I'm trying to create an action on the Chambre layer that ...
var29's user avatar
  • 51
2 votes
0 answers
527 views

Open file from QGIS and search for text within it

I have a lot of data associated with a layer in QGIS. Each individual feature has its own information associated with it - but this information is within a number of different PDF files. I have ...
PaigeC's user avatar
  • 21
2 votes
0 answers
502 views

Creating Action in Qgis

I'm trying to create an action in QGIS that open this link htt p://www.gulliver.it/itinerario-foto/14451/#!/uploaded/2014/large/20140929123749.jpg||grid2 but the character | is converted into %7C ...
Sandra's user avatar
  • 49
1 vote
1 answer
1k views

QGIS (python) action to open folder and search for string [closed]

I am using QGIS layer property actions. Is it possible for python to open windows explorer at a directory and then search for a custom string? Currently I can open windows explorer at the directory I ...
Jonathan West's user avatar
5 votes
1 answer
427 views

QGIS Layer Action Invoking an EXE

I am able to launch exe files from within QGIS actions without any problem, but when I try to launch one in particular (img2pdf.exe) I get an error. Syntax error: invalid syntax The command I am ...
Joebocop's user avatar
  • 339
3 votes
1 answer
2k views

how do I view geotagged photos and audio points in qgis mac?

How can I view geotagged photos and play audio files in qgis? For photos, HTML map tooltips used to work in qgis, but don't as of 2.18.2. For audio, I don't know of a solution.
jamierob's user avatar
  • 1,443
4 votes
1 answer
620 views

What is this 'Run layer action' and how to use it?

Following on from this question: Run QGIS layer Action on all selected features, a possible solution was to create an action in Python which iterated through the layer's selected features. If you ...
Joseph's user avatar
  • 74.6k
3 votes
1 answer
2k views

Run QGIS layer Action on all selected features

QGIS is such an amazing tool with lots of useful features, so that it's easy to overlook some of them. Just to be sure it's not already implemented in QGIS 2.18: Is there any Attribute Table option ...
christoph's user avatar
  • 4,661
3 votes
1 answer
3k views

Create an action in QGIS 2.18 to show image? [duplicate]

(Windows 10.1 and QGIS 2.18) I am trying to create an action for a Shapefile layer that will display an image when any of its three polygons are clicked. I have added an "image" field to the layer's ...
user avatar
17 votes
6 answers
19k views

Show images related to features in QGIS?

Say for example, if there's a point data with old trees, then when you use the identify tool, you can see the photograph of the tree Or even one level further, the labels displaying these images ...
Luffydude's user avatar
  • 2,258
6 votes
1 answer
399 views

QGIS action for inserting text in field by hotlink

I hope to make a simple action in QGIS, where the field in my layer column "Process" can change from "NULL" to "Finished". I use hotlink to click on the polygon in the layer, where I want the action ...
CLH's user avatar
  • 93
5 votes
2 answers
3k views

Zoom Canvas to Selected Features with Python call from QGIS Layer Action

I have been trying to get one layer's clicked-on feature to have an effect on another layer's viewed features with some success, but I am unable to get the map canvas to be filled by the the selected ...
gseggie's user avatar
  • 203
2 votes
1 answer
568 views

QGIS action that sets transparency in RGB raster

In the question: "GIS Action that loads a raster, creates pyramids and sets color" I have resolve the question for raster in B/W but now I need it to load RGB raster with white background that I would ...
Daniele Piccolo's user avatar
1 vote
1 answer
253 views

GIS Action that loads a raster, creates pyramids and sets color

Using the code in "Developing QGIS Action which loads a raster". from PyQt4.QtCore import QFileInfo,QSettings from qgis.core import QgsRasterLayer, QgsCoordinateReferenceSystem s = QSettings() ...
Daniele Piccolo's user avatar
1 vote
0 answers
115 views

Create an action that loads the rasters that intersect a polygon feature

Using part of the code in "Developing QGIS Action which loads a raster" from PyQt4.QtCore import QFileInfo,QSettings from qgis.core import QgsRasterLayer, QgsCoordinateReferenceSystem s = QSettings()...
Daniele Piccolo's user avatar
5 votes
2 answers
777 views

Developing QGIS Action which loads a raster

I'm using the action code of this question: "How to create a QGIS Action which loads a raster?" qgis.utils.iface.addRasterLayer('E:\\Plot Sheet Devt\\1974-1984\\1250k\\[% Grid_Ref %].TIF', '[...
Daniele Piccolo's user avatar
1 vote
1 answer
910 views

Click on an object to open an image using a QGIS action [closed]

I'm working on this answer from @Nathan W to find how to deal with missing files, as they return a error message if QGIS doesn't find any. The initial workflow is to be able to click on an object (...
gisnside's user avatar
  • 7,718
2 votes
0 answers
118 views

QGIS open action slightly changes my url when it tries to open it

I have an issue with creating active hyperlinks in QGIS. My url (after I deleted the site name) originally looks like this: ?type=canvas_rendering#%7B%22frame%22:%7B%22id%22:481350%7D%7D When I ...
HliasK's user avatar
  • 21
2 votes
1 answer
243 views

Start multiple processes with one action

I am trying to start multiple processes with a single action in QGIS. With Windows commands it is not hard, see here: https://stackoverflow.com/questions/13719174/how-to-execute-multiple-commands-in-...
Mario Rossi's user avatar
1 vote
1 answer
230 views

Adding actions or any other options?

I am pretty new with all GIS things and I have to prepare homework in QGIS. I have a shapefile which contains many buildings with their own grades. I want to make an automatic tool, solution, etc. to ...
mdgcrks's user avatar
  • 53
3 votes
1 answer
708 views

How to use regular expressions within QGIS Actions

I have stored html links in a column of a postgis layer. There are a few entries which have multiple links stored in one cell (blank separated). I have to use the firefox.exe to open the links in ...
Stefan's user avatar
  • 4,344
5 votes
1 answer
326 views

Create default QGIS actions / define my own default actions

I have created a simple action that should be used to several users. Then, I'd like to put my action among their default action list. Put it simply, how can I create a default qgis action in a given ...
Alex Pereira's user avatar
4 votes
1 answer
482 views

How to automatically load QGIS actions

There is something that I like alot in QGIS, and that is actions. From automatic wikipedia search, to opening an image, this use makes QGIS feel very dynamic. Unfortunately I have no idea how to ...
jhc's user avatar
  • 399
1 vote
0 answers
108 views

Creating an Action using the Value column in Value Relation widget

I want to create an Action that would use the attributes (such as report_id and county) of a site_investigation_report feature to generate a file path to a PDF report. The county attribute uses the ...
WhoDaHey's user avatar
  • 143
1 vote
1 answer
293 views

Can I mimic the "open" action in QGIS with python and manipulate the field content used for the action?

I am using QGIS actions (type: "open") to link ECM searches to objects on the map. The basic syntax is very simple: protocol://searchterm1=[%"field1"%]&searchterm2=[%"field2"%] However, some ...
MapEngine's user avatar
  • 965
2 votes
0 answers
160 views

Linking URLs through actions in .url format for QGIS?

I need to link some DWG files. Normally I'd do that with a simple cmd /c start ""[% "Link_DWG" %]"" where "Link_DWG" is an attribute containing the URL of the file. My problem is that I need to link ...
MapEngine's user avatar
  • 965
2 votes
1 answer
431 views

QGIS actions - get currently selected attribute column (with python?)

I'm trying to open files dynamically through actions. A simple example would be: Action name: OpenLink from PyQt4.QtCore import QUrl; from PyQt4.QtWebKit import QWebView; myWV = QWebView (None); ...
MapEngine's user avatar
  • 965
1 vote
0 answers
787 views

Embedding python to select feature in QGIS action

I am working from QGIS actions with python and want go to select the current feature that I've identified using the identify tool. (Key point is that there is a difference between identify and select)...
Andrew Bell's user avatar
1 vote
2 answers
355 views

QGIS2.6 postgis relation between tables

I have three tables in Postgis: points called location(gid (pkey),name) example (1,Paris) temperatures named Temp(idTemp(pkey),TempValue,date) example (1,12,2015-01-01) relation between the two: ...
Obi Wan's user avatar
  • 237
2 votes
1 answer
409 views

Is there an equivalent of ArcGIS Hyperlink script editor in QGIS?

I am trying to find similar functionality in QGIS to ArcGIS Hyperlink script editor. In ArcGIS I can parse VBScript from a selected field in an attribute table. The script would execute on mouse ...
roesa9's user avatar
  • 21
2 votes
0 answers
73 views

How to read and write to .txt in layer properties, action tab?

I want to write a certain attribute to a .txt file using the action tab in the layer properties (combined with Hotlink). In the QGIS-2.2-UserGuide, on page 97, there is an example on how to do that ...
Bebae's user avatar
  • 41
1 vote
0 answers
269 views

Openlayers pop-up FeatureSelected doesn't invoke even FeatureClicked works well

My code snippet is: //Vector Layer with listeners: var vectorLayer = new OpenLayers.Layer.Vector("Kuzzular"); vectorLayer.events.on({ 'featureselected': function(evt) { var ...
Ismail Yavuz's user avatar
5 votes
1 answer
332 views

QGIS 2.2 - possible to do a JOINS from the Action list?

I have a set of layers that need to be joined (Layer Properties > Joins) to one specific layer. The reason for this is that I will be updating and adding new layers into my project and would like a ...
Joseph's user avatar
  • 74.6k
2 votes
0 answers
439 views

How to set QGIS action to open and search for features on Google Maps?

At the moment, I have an action that takes each term in an address field and conducts a search on EACH term in Google (ie. multiple tabs are opened for each term). The action code I have is the ...
Joseph's user avatar
  • 74.6k
0 votes
1 answer
320 views

Modifying Fields in QGIS

I'm pretty new to Quantum GIS, and I was looking to add zeros to a field I was having some trouble with. I learned through browsing a few posts here that existing fields can be modified by defining ...
114's user avatar
  • 123
2 votes
2 answers
806 views

Open mail client when clicking feature in Attribute Table

One of the attributes/features of my layer contains an email address. I'd like to be able to open the default mail client by clicking on the mail address from the Attribute Table. After some initial ...
user28233's user avatar
  • 387
2 votes
1 answer
761 views

How to call a method by BOTH a button AND a key shortcut

I have been trying to call a method by BOTH a key shortcut (as described here http://www.qgis.org/en/docs/pyqgis_developer_cookbook/snippets.html) and a button I created on the toolbar. The button ...
mic's user avatar
  • 345
0 votes
1 answer
610 views

Opening shapefile linked custom metadata textfile within QGIS

I used a text file as a simple metadata for my shapefiles. It has basic information such as Source of raw data, Who can edit the file, Accuracy level, what those dbf filed means, Cost aquiring data, ...
Obsidianz's user avatar
  • 119
1 vote
2 answers
2k views

Qgis action adding layers using relative paths

in QGIS 2 windows I have some index layers I use for loading raster and vector tiles through an Python action. Currently I am using absolute paths which works fine but I would like to set it up so ...
Seth Loader's user avatar
3 votes
1 answer
3k views

Creating QGIS action which copies features between layers?

i tried (i never tried before...) to write a simple python code like action in QGIS on my "XXX" vector layer that: open a layer "YYY" copy the selected feature on my "XXX"layer paste the selected ...
user22892's user avatar