HP Forums

Full Version: Is there a way to sense when the screen is touched?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Something akin to ISKEYDOWN.

Page 558 of the User Guide.

Thanks in advance for any help.
you need to constantly be checking in a loop



local touch, X, Y;

WHILE ISKEYDOWN(4)<>1 do
wait(.1);
touch:=mouse();

if size(touch(1)) then
if touch(1,5)==0 then
X:=B→R(touch(1,1));
Y:=B→R(touch(1,2));
end;
end;


END;
You can also use WAIT(-1) which handles both keys and mouse events.
Thank you both for your help.
Reference URL's