With the proper diagnostic equipment the codes from a cars computer can still be read without having the check engine light on.
The check engine light only needs to be on when you have a place such as Autozone put their tool on your car to check the codes.
But a professional mechanic or auto shop can use a more expensive diagnostic tool that they connect to your vehicle to pull up the codes without the check engine light on.
So if your car is having trouble and you can't figure out the problem then taking the car to a mechanic who has diagnostic equipment can help find the problem.
The diagnostic equipment will tell them what is exactly going on with the car so that they can fix it quicker than just throwing parts at it.