Related to start and stop button

Hello,

I have arduino uno , SD shield 3.0, a MS5837 pressure sensor 3.3V .
I have programmed the arduino to read the pressure values from the pressure sensor and write the values to the SD card.

I'm trying to program a on/off button so that when I press the button, an led should glow and only then it will start writing to the SD card . If the button is pressed again, the led should stop glowing and it should stop writing the data to the SD card. (like a start/stop button for writing data to SD card). I'm beginner and please share your advice how to proceed.

Thanks!