Toggle buttons

  • Thread starter Thread starter Cherry
  • Start date Start date
C

Cherry

I created five toggle buttons on my forms so that users
can select different form to show up. For example: select
employee button to see employee detail or select report
to see report, but when user switch one to another form
it will hide the other(visible = false)

when I program the code on toggle button, I put them
under "On Got Focus". so, when user clicked on it and
hold it, the program will recognize that the button
already got focus eventhough users change their mind and
move mouse out. Is there anyway to protect in case user
doesn't change their mind and doesn't click on it.

Regard,
Cherry
 
I think that needs like that are best addressed by the AfterUpdate
events of the controls.

Pavel
 
All toggle events property that I have are On Got Focus,
On Lost Focus, On Mouse Down, On Mouse Move, On key Down,
On Key Up, On Key Press.

I don't see AfterUpdate event. Please advise.

Cherry.
 
-----Original Message-----
I created five toggle buttons on my forms so that users
can select different form to show up. For example: select
employee button to see employee detail or select report
to see report, but when user switch one to another form
it will hide the other(visible = false)

when I program the code on toggle button, I put them
under "On Got Focus". so, when user clicked on it and
hold it, the program will recognize that the button
already got focus eventhough users change their mind and
move mouse out. Is there anyway to protect in case user
doesn't change their mind and doesn't click on it.

Regard,
Cherry
.


There is a very simple code that you need to write
inorder to get rid of this problem, you will have to
write nested if or iif statement on On_Click event of the
toggle buttons and will have to check in each if block
that whether the current toggle button is clicked or not.
 
Oops! On Click event - Vaibhav is right.
Sorry for the misleading post! I was thinking about text fields. My fault.

Pavel
 
Back
Top