Is there a way to create a loop or repeat function that continuously updates the current time in a field? I have been trying to make this work with something like below:
on preOpenCard
repeat forever
put the time into fld "time"
if fld "time" is "12:00 PM" then
answer "Blah blah blah"
else
end if
end repeat
end preOpenCard
--But this just either loops the blank screen until a condition is met, or it will not put the time in the "time" field....I would like to have the loop check the time until a certain time is met then send a msg to the user, then keep looping until that time is met once again...and so on.....
thanks for the help
repeating time in field
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Re: repeating time in field
You could use something like this...
Code: Select all
on openCard
setTime
end openCard
on setTime
put the seconds into tempTime
-- if tempTime = whatever then
-- do whatever
-- end if
convert tempTime to long time
put tempTime into fld 1
send "setTime" to me in 1 second
end setTime
You will have to juggle with the seconds, but this should get you started
be well
Dixie
Re: repeating time in field
Thank you Dixie for taking the time to help! Im going to try this code out now...have a great week...