Unfortunately that kind of broadcasting has nothing to do with SMS, and a solution you find for c++ isn't going to help much for ASP.NET, at least not out of the box.
You're likely looking for a
messaging gateway[
^] (
here's more[
^]).
You would either be able to manage the groups locally in a database you create, or some services actually feature APIs to allow this kind of functionality (students vs teachers vs parents, for example).
Cheers.