BrowserWindow.
This functionality is supported only if you are using the Open Agent.
alertText = browserWindow.GetAlertText()