Is there a way in the Print Composer of QGIS to create a label that will automatically update the date (systems date) instead of having a label that you have to manually have to update?
1 Answer
Yes, you can add
format_date( now(),'yyyy-MM-dd HH:mm:ss')
This used to be the old syntax:
$CURRENT_DATE(yyyy-MM-dd)
-
8In QGIS3, if adding as a label in your Layout, you could add this code to the Label item's 'Main properties' text box [% format_date( now(),'MM/dd/yyyy') %]– cm1Commented Aug 3, 2018 at 15:59
-
It it possible to choose the output language? I would like to show the date in French fr_FR format.– ZKBCommented Jul 27, 2021 at 16:12
-
-
$CURRENT_DATE(yyyy-MM-dd) still works, and without an expression. twitter.com/qgis/status/144365563752349696– HeikkiVesanto ♦Commented Oct 17, 2022 at 11:35