Hi Jeff
Hi Jan,
I *think* I'm following you now.
I believe in this case with option buttons the best bet is to NOT have a
default button at all in
your Option Group frame. By clearing the Default value of the OG frame on
the property sheet, the
form will open with none of the buttons 'depressed.' This way you will not
have to click another
option first just to 'un-press' the one you really want. The form will
open ready to make a
selection. Is that what you are after?
Yup! That worked a trick! Apparently, the last one I created trying to
get them right, set the 1 as Default without my noticing the setting. I
deleted the 1 in the Default setting and now there is nothing selected when
the form opens, and all the buttons are working as desired when clicked.
Thanks Jeff, and Happy Thanksgiving!
......174 days 11 hrs 56 mins 42 secs and counting ;o)
Hi Jeff
Hi Jan,
So nothing happens when any of the options are selected or just the
first
one?
Make sure that the property sheet has [Event Procedure] listed for the
After Update
of this control.
Yes, each one works fine. It's just that whichever one is the one
already
selected (highlighted) when the form opens, if you click on it, nothing
happens. You have to first click on one of the others that is not
highlighted, then come back to the first one to get it to work.
Also, what are the values of each option (listed in the property
sheet) if
you don't mind?
1, 2 and 3, respectively. Example, if 1 is the one that is highlighted
or
has the focus when the form is first opened, then if I want to use that
button to open the form, when I click on it nothing happens.
Jan
Hi Jeff
Hi Jan,
Sorry for the delay; tried to cram in three days of work into one.
From your description you must be using toggle buttons in the
option
group??
Do you have some code in the After Update event of this option
group?
Normally that is where you will place code to have the option
group
"do something" when you make a selection.
Not a problem..BTDT
Yes...they are the small round button, and
here is
the Event Procedure code that Steve Shapel helped me with in the
queries
group that is in the After Update Event. I thought this might be
where
the
code should go as well, but, not sure if it would apply in this
case,
this
being my first experience with OG's.
Private Sub fmeOptionGrp_AfterUpdate()
DoCmd.OpenForm "frmCheckRegister"
With Forms!frmCheckRegister
Select Case Me.fmeOptionGrp
Case 1
.RecordSource = "SELECT * FROM qryCkRegisterDan WHERE
CheckNo
Not
Like 'DBT*'"
Case 2
.RecordSource = "SELECT * FROM qryCkRegisterDan WHERE
CheckNo
Like
'DBT*'"
Case 3
.RecordSource = "qryCkRegisterDan"
End Select
End With
End Sub
Thank you for your time and help.
Jan
Hi Jeff!
Hi Jan,
Right click on the option group frame and go to Properties.
On the Data or All tab is the option "Default Value."
Change that value to match the option you want as the default.
If you used the wizard the options will usually be 1, 2, 3,
etc.
'k...I got this done okay. And the button Value 1 is the
default.
However,
when I click on this button, which is already selected, nothing
happens.
The Record Form does not open. Even double
clicking.....just....nothing.
Is there something else I am supposed to do to get the default
button to
activate when clicked on?
Thank you very much for your help, I really do appreciate it.
Jan
Smiles are meant to be shared,
that's why they're so contagious.
If you are unsure, right click on each individual radio
option,
check
box,
etc and look
for "Option Value." That will tell you the number (or text) to
be
put
in
the Default
Value for the option group.
--
Jeff Conrad
Access Junkie
Bend, Oregon
Hi all
Access 2002 XP, W2K
I have a form with a new Option Button, and when creating
it, I
forgot
to
select a default button. Is it possible to define the
default
button
on
the
GO post creation? What is happening at this point, is that
the
last
button
selected is still the one selected when the form is opened
again.
If it
is
the one that I want to use at the moment, I have to first
select
one
of
the
other buttons, which opens the Record Form, then I have to
close
the
Record
Form, go back to the Filter form where the OG is, and then
select
the
button
I really want. This, I would like to be able to have the
default
button
be
the one that has the focus when the form is opened. Is it
possible
to
add a
separate button and give this the focus when the form is
opened
to
clear
the
buttons on the OG? Or..... do I have to recreate a new OG.
This is my first OG, so I'm not that familiar yet with how
they
work.
I'd
truly appreciate any suggestions on what is the best way to
do
this.