I am setting up a hectare grid in QGIS 3.0 using Vector > research tools > create grid > grid type:point and then defining boundaries by a preexisting polygon layer. I would like to get coordinates from these points but the x and y axis created seem to be defined not by the CRS but by seemingly arbitrary numbers. Is there a way I can get coordinates into the attribute table? When I identify feature, I can find the actual lat/long coordinates but I cannot figure out how to import these into the attribute table.
- Open the attribute table
- Add two fields: X and Y in the attribute table with a Decimal Number (real) type, and length 10
- Select the X field from the drop-down menu, write in the expression
$Xand click on update all
- Select the Y field from the drop-down menu, write in the expression
$Yand click on update all
- Save edits and stop editing.