<html><body><div style="font-family: times new roman, new york, times, serif; font-size: 14pt; color: #000000"><div></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">Dear list,<br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">here is my PyQGIS script:<br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">##Points=vector</span><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">layer_point = processing.getObject(Points)</span><br><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">iter = layer_point.getFeatures()</span><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">for point in iter:</span><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"> print "Feature ID %d: " % point.id()</span><br><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"> geom = point.geometry()</span><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"> if geom.type() == QGis.Point:</span><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"> x = geom.asPoint()</span><br><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"> print " Point: " + str(x)</span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><br style="font-family: courier new,courier,monaco,monospace,sans-serif;"></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">It always returns " Point: (0,0)" for each geometry<br></span></div><div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;" data-mce-style="font-family: courier new,courier,monaco,monospace,sans-serif;">despite <span style="font-family: courier new,courier,monaco,monospace,sans-serif;" data-mce-style="font-family: courier new,courier,monaco,monospace,sans-serif;">layer_point</span>.extent().toString() returns:<br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;" data-mce-style="font-family: courier new,courier,monaco,monospace,sans-serif;">"402100.4306666287011467,429938.4182564518414438 : 402469.0222782648634166,430309.6282568128081039"</span></div></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">Would you know how i can debug this?<br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">Thank you in advance.</span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">Regards,<br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;">Adrien<br></span></div><div><span style="font-family: courier new,courier,monaco,monospace,sans-serif;"><br></span></div><div></div></div></body></html>