I have to try the extract data from Google Chrome alert message text. But when I use Get Text activity and click on Indicate On Screen alert box not highlighted.
Whole browser windows selected highlighted instead of.
I have stuck to extract Reports - Upload Yearly Report confirmation id from alert box.
A proper way to solve this is image recognition. So you search for the OK button as image. You can do that with the Click Image activity.
But in case you are using the process with another language you might have some issues.
Update: You said you need the text. So you could try the UiPath Connect Browser Get PopUp Text. Note that this only works on Chrome.