Rainer2000
IS-IT--Management
I have written the following code in a Form:
Private Sub Befehl90_Click()
If Me.Text86 < #12/31/1988# Then Text69 = "ERW"
If Me.Text86 >= #1/1/1989# And Me.Text86 < #12/31/1990# Then Text69 = "U19"
If Me.Text86 >= #1/1/1991# And Me.Text86 < #12/31/1992# Then Text69 = "U17"
If Me.Text86 >= #1/1/1993# And Me.Text86 < #12/31/1994# Then Text69 = "U15"
If Me.Text86 >= #1/1/1995# And Me.Text86 < #12/31/1996# Then Text69 = "U13"
If Me.Text86 >= #1/1/1997# And Me.Text86 Then Text69 = "U11"
End Sub
This Code calculates in which age category the members of my team comes.
This works fine: I am using a Doubleclick Code to calculate.
I have been trying to automatize this Code so it will walk through the whole database and calculeate for each recordset when clicking on the calculate button on the Form.
Something like : Do While Not EOF, but I could not make it work.
Any help available?
Rainer
Private Sub Befehl90_Click()
If Me.Text86 < #12/31/1988# Then Text69 = "ERW"
If Me.Text86 >= #1/1/1989# And Me.Text86 < #12/31/1990# Then Text69 = "U19"
If Me.Text86 >= #1/1/1991# And Me.Text86 < #12/31/1992# Then Text69 = "U17"
If Me.Text86 >= #1/1/1993# And Me.Text86 < #12/31/1994# Then Text69 = "U15"
If Me.Text86 >= #1/1/1995# And Me.Text86 < #12/31/1996# Then Text69 = "U13"
If Me.Text86 >= #1/1/1997# And Me.Text86 Then Text69 = "U11"
End Sub
This Code calculates in which age category the members of my team comes.
This works fine: I am using a Doubleclick Code to calculate.
I have been trying to automatize this Code so it will walk through the whole database and calculeate for each recordset when clicking on the calculate button on the Form.
Something like : Do While Not EOF, but I could not make it work.
Any help available?
Rainer