How do I find the x and y co-ordinates of a tap in a canvas?

So, I want to create an Image Markup. For that, I want a point to appear on the image on the canvas where ever there was a tap. There, it is asking for the x and y coordinates. How do I find the x and y coordinates of where the tap occurred on the canvas?

image

3 Likes

Welcome to the community. You can use when canvas touched block to get x,y coordinates for example

image

4 Likes

Your example is more complete :grin: :+1:

1 Like

image

:wink:

4 Likes

Even better example @TIMAI2 :slight_smile:

2 Likes

Thanks a lot. Can you also say how I can use these co-ordinates to draw a point in these co-ordinates?

You could use draw point block

image

2 Likes

Thanks a lot.

1 Like

Have you done the Paint Pot Tutorial yet?

1 Like

No, I am following a different school project.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.