Wednesday, 18 March 2015

Getting feature attribute description with pyqgis?


I have a vector layer which attributes have value maps and I need to get the description of value. I am able to get the values with feature.attributes(), but I haven't found a way to get the description.enter image description here


layer = canvas.currentLayer()

attributes = feature.attributes()
print attributes[5] # prints 0, but I need Unknown


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...