my plan was to use mouseDown to initiate a timer, but I keep getting a compile error
so really I have 2 questions:
1. how do I need to work my "schedule timer" command
2. is there a better way to try and hold down a button?
Code: Select all
public handler OnMouseDown()
variable tNum as Number
put mText parsed as number into tNum
add 1 to tNum
put numToString(tNum) into mText
put true into mTester
redraw all
schedule timer in 1 second
end handler
public handler OnTimer()
if mTester is true then
put mText parsed as number into tNum
add 1 to tNum
put numToString(tNum) into mText
put true into mTester
redraw all
if tNum < 100 then
schedule timer in 1 second
end if
end if
end handler
public handler OnMouseUp()
put false into mTester
end handler
Code: Select all
3:30 PM: Error: on line 142 ():
3:30 PM: Error: /Users/pink/Dropbox/My LiveCode/Documents/LCB My Testground/PracticeWidget/pratice.lcb:142:36: error: Parsing error: syntax error
schedule timer in 1 second
^
3:30 PM: Error: failed to compile module