Don't fret about not having a BF for your Valentine's Day Dance. Just hang out with your friends and have fun! Sure, it'd be nice to have a BF, but it shouldn't be a priority in your life right now. Where I live, people don't start dating until they're grades 10-12, rarely younger than that. You've been friends with him awhile, so maybe if he does like you he still doesn't wanna go out with you because it could wreck your friendship. Don't prioritize a boy over your marks, if you can get into better classes, go for it. Chances are, this boy won't be a major part of your future, would you want to wreck your chances at a good college or university just for a boy? If you and him are really good friends it shouldn't matter if you're not in all of the same classes, you can still hang out and talk outside of school or during breaks and lunches. Remember, this is a school crush, and the people around you are going to change as they get older, including you. Chances are you're not going to like this boy in a few years or even a few months.
If he really likes you, and doesn't have a GF, he'll ask you out. Especially if he knows you like him. If he does, that's awesome. If he's just broken up with a girl he really liked, let him get over her first. And do not get a friend to ask him out for you, it doesn't make you look good.
Hopefully this helps and everything works out, and I do speak from my own and my friends' experiences here.

EDIT: Hun, I've never even had a BF before and it's not a big deal. I still go to all the dances and just hang out and dance with my friends. If him and his GF are off and on a lot, there's nothing you can do about it, especially if he really likes her. Just try and have fun, don't stress about tings that won't be important in a few years
