IF the code is caused by the fuel cap, it is not stored in the ECM memory as a priority code. These can be deleted by disconnecting the battery for up to 15 mins. Priority codes, however would not be deleted by this. However, as stated above, you want to know what the trouble code is simply have it read with an OBDII scanner.