Related example macro: Demo-OnJavascriptDialog
iMacros handles all Javascript dialog boxes for you using the ONDIALOG command. You can extract the text of a dialog by adding SET !EXTRACTDIALOG YES to your macro.
Tip: On some pages, a new page loads once a button on the dialog is clicked. If you want iMacros to wait for this page to load before continuing, please add WAIT SECONDS=#DOWNLOADCOMPLETE# after the TAG statement that triggers the dialog box.
Page URL http://www.iopus.com/imacros/help/dialog_javascript.htm