I have been trying for a long time to connect a external table data[csv] through Excel (for exmaple) with QGis with the objective to each time i change any data in table(for example data location - coordinates [X ; Y]),this changes occur in QGis real time.

Is there any procedure to get it?.

1 Answer 1


Although the original question was aimed at raster layers, the same procedure can be applied here with simple python scripting. See https://gis.stackexchange.com/a/58885/9839

from qgis.PyQt.QtCore import QFileSystemWatcher

def refreshLayer():
    myLayer.setCacheImage( None )

watcher = QFileSystemWatcher()
watcher.addPath( '/path/to/your/csv' )
watcher.fileChanged.connect( refreshLayer )
  • Note this answer does not work for modern versions of QGIS.
    – Mike T
    Jul 21, 2020 at 22:13
  • Fixed, please check the update Jul 23, 2020 at 12:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.