ToggleButton issue

  • Thread starter Thread starter Joao
  • Start date Start date
J

Joao

Hi all and good day. I have 3 ToggleButtons framed. OptionValues are 1,2 and 3.
What I want to do and I can't... is... to load the form with the first
togglebutton already pressed. I've tried almost everything and I still can't
accomplish the mission...

like this
tglbuttonLemon.optionvalue=1 at the form_load
or
tglbuttonApple.optionvalue=true .....

etc...
Anyone can help me in this thing I think it's quite simple?
 
Joao said:
Hi all and good day. I have 3 ToggleButtons framed. OptionValues are 1,2
and 3.
What I want to do and I can't... is... to load the form with the first
togglebutton already pressed. I've tried almost everything and I still
can't
accomplish the mission...

like this
tglbuttonLemon.optionvalue=1 at the form_load
or
tglbuttonApple.optionvalue=true .....

etc...
Anyone can help me in this thing I think it's quite simple?


You need to set the Value property of the option group that contains the
toggle buttons. For example, the following code will select the second
toggle button ...

Private Sub Form_Load()

Me.Frame0.Value = 2

End Sub

.... where "Frame0" is the name of the option group that contains the toggle
buttons.
 
As I thought, pretty easy... pitty sometimes we block and feel stupid...lol
Thanks Brendan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top