If you enter on a student visa you cannot work. You have to have a work visa to work legally. But you can certainly study while holding a work visa.