| View previous topic :: View next topic |
| Author |
Message |
jwfv Valued Contributor

Joined: 19 Mar 2002 Posts: 422 Location: Beaufort, SC
|
Posted: Wed Feb 04, 2004 6:52 pm Post subject: Setting state of checkbox |
|
|
I have an application that has a checkbox with a CLICK event when it is checked. Sometimes the appliacation needs to set the checkbox as checked, but I don't want the event to fire. Right now it does.
Is there a way to set the checkbox without firing an event?
I saw this forum topic, don't know if this is close to what I need or not:
http://forum.vdsworld.com/viewtopic.php?t=1827&highlight=checkbox+click+event
One thought: is there a way to remove the CLICK style, set the checkbox, then re-apply the CLICK style?
Thanks for any help. _________________ Joe Floyd |
|
| Back to top |
|
 |
Vic D'Elfant Past Contributor


Joined: 26 Jun 2002 Posts: 673 Location: The Netherlands
|
Posted: Wed Feb 04, 2004 7:04 pm Post subject: |
|
|
FreezingFire's API works at my PC I've tested it with a checkbox with CLICK style...
And re-applying the CLICK style would result in a flashing dialog, because you'll have to remove and add the checkbox again
Regards,
Vic _________________ phpBB Development Team |
|
| Back to top |
|
 |
jwfv Valued Contributor

Joined: 19 Mar 2002 Posts: 422 Location: Beaufort, SC
|
Posted: Wed Feb 04, 2004 7:13 pm Post subject: |
|
|
Thanks for the reply. I guess I can figure out his example and how to apply it to my program. If it doesn't fire the CLICK event, then it should be just what I need. _________________ Joe Floyd |
|
| Back to top |
|
 |
LiquidCode Moderator Team
Joined: 05 Dec 2000 Posts: 1753 Location: Space and Time
|
Posted: Wed Feb 04, 2004 8:23 pm Post subject: |
|
|
You should be able to "throw away" the event after you set your check box.
Something like:
| Code: |
Dialog set,Check1,1
%e = @event()
# Continue your script
|
That should work _________________ Chris
Http://theblindhouse.com |
|
| Back to top |
|
 |
Tommy Admin Team
Joined: 16 Nov 2002 Posts: 746 Location: The Netherlands
|
Posted: Wed Feb 04, 2004 9:14 pm Post subject: |
|
|
I would feel safer to go with:
| Code: | Dialog set,Check1,1
wait event
%e = @event()
# Continue your script |
Because then you know for sure the event really already occured before throwing it
away. As there's no knowledge how VDS internally handles events it just might be
true that the event could get lagged a bit and it would only occur just after the
"%e = @event()" line if omitting the "wait event".
Tommy |
|
| Back to top |
|
 |
LiquidCode Moderator Team
Joined: 05 Dec 2000 Posts: 1753 Location: Space and Time
|
Posted: Wed Feb 04, 2004 9:23 pm Post subject: |
|
|
True. Didn't think of that Tommy. _________________ Chris
Http://theblindhouse.com |
|
| Back to top |
|
 |
jwfv Valued Contributor

Joined: 19 Mar 2002 Posts: 422 Location: Beaufort, SC
|
Posted: Wed Feb 04, 2004 9:29 pm Post subject: |
|
|
Hey - that's an even simpler idea. Thanks. I'll try it out. _________________ Joe Floyd |
|
| Back to top |
|
 |
|