Everytime I hit Play on the launcher, it closes, then reopens and gives me an error message. I tried uninstalling the game completely and then reinstalling, and it didn't work. I also tried to reinstall Java but I'm still getting this error message.
Related issues
Attachments
Comments

Thank you for your report!
However, this issue has been temporarily closed as Awaiting Response.
We do not have enough information to find the cause of this issue.
Please attach the crash report (.minecraft/crash-reports/crash-<DATE>-client.txt) here.
If no crash report was created, please attach the launcher log (.minecraft/launcher_log.txt) here.
Once attached, the report will be reopened automatically.
Quick Links:
📓 Issue Guidelines – 💬 Community Support – 📧 Customer Support – 📖 Game Wiki

I added it.
Thank you for your report!
However, this issue has been closed as a Duplicate of MC-121285.
This is caused by using a custom resolution when launching the game. Until this issue is fixed, please disable this option in the profile you use.
Quick Links:
📓 Issue Guidelines – 💬 Community Support – 📧 Customer Support – 📖 Game Wiki