Age categories

pavol_b

New member
Local time
Today, 17:42
Joined
Mar 15, 2005
Messages
6
hi,
the proceedure to calculate age in years from a birth date is clear. but i have another issue, concerning calculaction of "age categories", like Junior, Cadet and Senior.
the known value is again birth date. the age <= 15 should be like Cadet, <=18 should be like Junior and >18 should be Senior. i have no idea, how to define a formula devided from birth date.
can somebody help me please? thank you in advance.

/Pavol
 
Try something along the lines of;
Code:
If Me.Age <= 15 Then
     Me.Category = "Junior"
Else IF Me.Age >15 And Me.Age <= 18 Then
     Me.Category = "Cadet"
Else
      Me.Category = "Senior"
End IF
 
Hi -

As an alternative, you might try the Switch() function, e,g,

Code:
x = 16
? switch(x<14, "Cadet", x<=18, "Junior", True, "Senior")
Junior

HTH - Bob
 

Users who are viewing this thread

Back
Top Bottom