I too was laboriously trying to fix the greyed-out screen-capturing buttons. At first, I tried repairing Xbox game bar, and then resetting it, but nothing. Then, editing the registry - also nothing. Updating Xbox game bar - nothing. Alas, I went to the Microsoft store, and noticed that under Xbox game bar, it not only said 'Open' but also 'Get'. Miraculously, that is what fixed the issue.
Just thought I would share my experience is all. I had been trying to fix it for hours lol.