Private Sub cboMuscleGroup_Click()
frmExcercise.lstExercise.Clear
for each cell in worksheets("Exercise").Range("A1:A10)
if cell.Value = frmExcercise.cboMuscleGroup.Value then
frmExcercise.lstExercise.AddItem cell.offset(0,1)
end if
Next
End Sub
Assumes A1:B10 is a list with musclegroup in column A and exercise in column
B
--
Regards,
Tom Ogilvy
"Jon" wrote in message
...
Hi
I have 2 worksheets (musclegroup and exercise)
I loop in the values from musclegroup into a combobox,
the combobox listindex is the same as the ID(A).
Now I want to fill up the exercises(column B in worksheet exercise) into
the frmExercise.lstExercise
that correspond to the musclegroup I select in frmExercise.cboMusclegroup.
Is there a simply way
Regards
Jon
Follow the link below, explains and shows the userform and worksheets
http://www.johak.se/index.html