Hello and welcome to Just answer.com, Super mechanic here. About your vehicle.
The service engine light will come on when there is a malfunction in the powertrain control system, including any evaporative emmission related problems. The check gas cap is directly related to the engine light being on. The gas cap could be bad, (not sealing) or there could be a leak in the evap system.
The best thing to do would be to have the codes read, (normally autozone and such will do that free of charge) to see which trouble code(s) has caused the both lights to come on.
When we know the code(s) we will have a better idea as to which area the concern may be in, thanks