Thanks, Bob. I tried that, but no luck.
Here's what I'm struggling with:
If Option1 Then
Me.From_File.Value = 8000
Me.To_File.Value = 9000
ElseIf Option2 Then
Me.From_File.Value = 0
Me.To_File.Value = 7999
ElseIf Option3 Then
Me.From_File.Value = 0
Me.To_File.Value = 9000
End If
In option 2 I want to also include values 9001 to 15000.
Joe
> > Hi,
> >
[quoted text clipped - 21 lines]
>
> Bob
MikeD - 31 Dec 2004 04:08 GMT
> Thanks, Bob. I tried that, but no luck.
> Here's what I'm struggling with:
[quoted text clipped - 11 lines]
>
> In option 2 I want to also include values 9001 to 15000.
Let me make sure I understand. You want both 0 and 9001 assigned to
Me.From_File.Value and both 7999 and 15000 assigned to Me.To_File.Value?
You can't. Only one value at a time can be assigned to each of the Value
properties. One thing you could do is assign values as follows:
Me.From_File.Value = 0
Me.To_File.Value = 15000
and then include a condition to skip values 8000 to 9000 (assuming there's a
loop somewhere). Or, you might perform the action(s) for the first range of
values and then repeat those actions for the second range of values.
Another possibility would be to add a 4th option button that is only enabled
if Option2 is enabled (thusly allowing the user to select either range for
Option2).
Knowing exactly what these values represent and how you're using them might
help us formulate better alternatives for you. It's pretty obvious they are
for sets of files, but it's unclear how what they actually represent
(probably part of the file names, but that's conjecture). It's not even
clear if you're even looping through the ranges of values. The more
information we have, the better we can help. It's always better to just
provide as much information as possible up front than for us to have to
query for it. That just takes more time for us to be able to help you.
BTW, you should not rely on default property values. It's a bad habit to get
into and eventually will lead to trouble (particularly if you ever change to
VB.NET). Besides that, it just makes your code less readable and concise.
IOW, you should use Option1.Value, Option2.Value, Option3.Value.
Mike