User button programmed for Pi startup

I am new to the world of Raspberry Pi and the 3G/4G hat is for a project that I’m working on in amature radio. I would like some help in how to program the user button associated with GPIO pin 22. All i am wanting to do is use the button to turn on the Pi. The hat is on a Pi 4b. Even if someone can point me in the right direction of where to look or more resources. Thanks in advance for the help.