The renewal maintenance has officially ended for Progress iMacros effective November 30, 2023.
This Wiki site will also no longer be moderated from the Progress side.
Thank you again for your business and support.
Sincerely, The Progress Team
Difference between revisions of "Web Page Dialogs"
Line 1: | Line 1: | ||
− | How to automate Web Page Dialogs | + | '''How to automate Web Page Dialogs''' |
This is a collection of tips and tricks on how to automate web page dialogs (WPD). These dialogs are IE only. Technically they are created by either a [http://msdn2.microsoft.com/en-us/library/ms536759(VS.85).aspx ShowModalDialog] or [http://msdn2.microsoft.com/en-us/library/ms536759(VS.85).aspx showmodelessDialog] command. They are not tabbed web pages and Internet Explorer (and the iMacros Browser) can not open then inside a tab. But iMacros has several methods to automate and test such dialogs. | This is a collection of tips and tricks on how to automate web page dialogs (WPD). These dialogs are IE only. Technically they are created by either a [http://msdn2.microsoft.com/en-us/library/ms536759(VS.85).aspx ShowModalDialog] or [http://msdn2.microsoft.com/en-us/library/ms536759(VS.85).aspx showmodelessDialog] command. They are not tabbed web pages and Internet Explorer (and the iMacros Browser) can not open then inside a tab. But iMacros has several methods to automate and test such dialogs. | ||
− | 1. Use the [[Browser_Automation#Web_Page_Dialogs|Dialog Manager]] | + | '''1. Use the [[Browser_Automation#Web_Page_Dialogs|Dialog Manager]]''' |
Advantage: | Advantage: | ||
Line 11: | Line 11: | ||
Disadvantage: Tabbing from line to line is complicated and error-prone on complex screens. Click command needs to be created manually. | Disadvantage: Tabbing from line to line is complicated and error-prone on complex screens. Click command needs to be created manually. | ||
− | 2. Use [[DirectScreen]] | + | '''2. Use [[DirectScreen]]''' |
DirectScreen can be used to automate all modeless dialog Windows. | DirectScreen can be used to automate all modeless dialog Windows. | ||
Line 17: | Line 17: | ||
Disadvantage: Does not work on modal dialogs (recording works, but replay fails because the dialog stops the application. This is not a bug in iMacros, IE behaves the same way). | Disadvantage: Does not work on modal dialogs (recording works, but replay fails because the dialog stops the application. This is not a bug in iMacros, IE behaves the same way). | ||
− | 3. Try to open the dialog in a tab | + | '''3. Try to open the dialog in a tab''' |
'''If''' this methods works, it is very powerful and highly recommend. So we recommend to test this method if you need to automate complex web page dialogs: | '''If''' this methods works, it is very powerful and highly recommend. So we recommend to test this method if you need to automate complex web page dialogs: |
Revision as of 23:27, 2 January 2008
How to automate Web Page Dialogs
This is a collection of tips and tricks on how to automate web page dialogs (WPD). These dialogs are IE only. Technically they are created by either a ShowModalDialog or showmodelessDialog command. They are not tabbed web pages and Internet Explorer (and the iMacros Browser) can not open then inside a tab. But iMacros has several methods to automate and test such dialogs.
1. Use the Dialog Manager
Advantage: This method works well for simple dialogs. Semi-visual recording with the dialog manager Click-command can also click on buttons on modal windows (Use DirectScreen recording to get the coordinates you need, then insert a Template:CLICK 11 22 command in the ONWEBPAGEDIALOG line. Disadvantage: Tabbing from line to line is complicated and error-prone on complex screens. Click command needs to be created manually.
2. Use DirectScreen
DirectScreen can be used to automate all modeless dialog Windows. Advantage: Very powerful, supports even drag&drop, mouseover and Image Recognition on the dialog. Disadvantage: Does not work on modal dialogs (recording works, but replay fails because the dialog stops the application. This is not a bug in iMacros, IE behaves the same way).
3. Try to open the dialog in a tab
If this methods works, it is very powerful and highly recommend. So we recommend to test this method if you need to automate complex web page dialogs:
a. Get the URL of the dialog window. It you open the dialog window inside Internet Explorer (not the iMacros Browser) the dialog has an address field. Get the URL from there.
b. Now use the iMacros Browser. Open a new tab and paste the URL from step (a). Often, the dialog window opens now inside a tab. You can now use the normal recording features (TAG,...) to automate the dialog!
c. Sometimes the SAVE function of a dialog does not work when opened as tab (data is not send to a server). We found that often the data is still stored by the website locally (e. g. using internal Javascript or cookies). So when you open the dialog method using method (1) it has the correct data and all you need to do is to click the SAVE button of the dialog.