4

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.

  • What CRS is the point grid layer in? – csk Jul 20 '18 at 1:54
  • I have tested, and i have the goods x, y attributs in the fields "left" and "top". This fields are automaticaly created whis the tool "create grid". Are you sure you have choose the same CRS as your project when you created the point layer? – Christophe Jul 20 '18 at 6:43
3
  1. Open the attribute table
  2. Add two fields: X and Y in the attribute table with a Decimal Number (real) type, and length 10
  3. Select the X field from the drop-down menu, write in the expression $X and click on update all
  4. Select the Y field from the drop-down menu, write in the expression $Y and click on update all
  5. Save edits and stop editing.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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