If you are currently out of status and your work permit was refused, your application for a study permit will be refused as well. You may apply for restoration of your status as a worker or visitor within 90 days after your work permit expired. For a work permit restoration you would need an approved LMO which is not easy to get. If you get a visitor status upon restoration, you won't be able to apply for a Study Permit from within Canada.
When you applied for extension of your work permit, did the province of Alberta provide you with a supporting letter allowing to apply for a bridging work permit?