Hello everyone,
I started out with creating extension just few weeks ago so forgive me if I ask anything wrong.
I want to know how to interact with various components in the App Inventor.
Example:
I want to draw a point on the Canvas using a @SimpleFunction
in my extension. So, I take the coordinates and the Canvas Component as the inputs.
The Canvas component has a method DrawPoint(x,y)
.
How can I call this function from within the extension?
This is how far I went.
@SimpleFunction(description = "Plots a point")
public void plot(int x, int y, canvas component) {
component.DrawPoint(x, y);
}