Data range Question - Very easy (1 Viewer)

Benjamin Bolduc

Registered User.
Local time
Today, 06:57
Joined
Jan 4, 2002
Messages
169
Hello,

I get stuck on the simplest things. I need to write an If-Then statment for a report Im working on that establishes a basic data range from .25 to .5

For Example:

If Efficiency < .5 and > .25 then
blahblah
End If

I've tried so many combinations, including Between but I just can't seem to get the format down right.

Can anyone help me out?

Thanks!
Ben
 

antomack

Registered User.
Local time
Today, 11:57
Joined
Jan 31, 2002
Messages
215
Try

If Efficiency Between 0.25 and 0.5 then
what to do
End if
 

Benjamin Bolduc

Registered User.
Local time
Today, 06:57
Joined
Jan 4, 2002
Messages
169
Thanks for the reply.

That didn't work though. I got a compile error saying it expected then or goto? Any other ideas?

Thanks!
Ben
 

antomack

Registered User.
Local time
Today, 11:57
Joined
Jan 31, 2002
Messages
215
Actually yeah now that I look back at it that syntax would be wrong.

You could do
If Efficiency < 0.5 and Efficiency >0.25 then

or use
Select Case Efficiency
Case 0.25 to 0.5
what to do?
case else
what to do?
end case
 

Benjamin Bolduc

Registered User.
Local time
Today, 06:57
Joined
Jan 4, 2002
Messages
169
I really should have known that. I think I need some more coffee this morning. Thanks for the help! :)
 

Users who are viewing this thread

Top Bottom