Let X be the number of students in the middle school. We know that X*20% = 168 students are in the band.
So there are X = 168/20% = 840 students in the middle school.
#### 840