How to make a loop?

Discussions and Tech Support specific to the iMacros Firefox add-on.
Forum rules
iMacros EOL - Attention!

The renewal maintenance has officially ended for Progress iMacros effective November 20, 2023 and all versions of iMacros are now considered EOL (End-of-Life). The iMacros products will no longer be supported by Progress (aside from customer license issues), and these forums will also no longer be moderated from the Progress side.

Thank you again for your business and support.

Sincerely,
The Progress Team

Before asking a question or reporting an issue:
1. Please review the list of FAQ's.
2. Use the search box (at the top of each forum page) to see if a similar problem or question has already been addressed.
3. Try searching the iMacros Wiki - it contains the complete iMacros reference as well as plenty of samples and tutorials.
4. We can respond much faster to your posts if you include the following information: CLICK HERE FOR IMPORTANT INFORMATION TO INCLUDE IN YOUR POST
Post Reply
pello
Posts: 2
Joined: Fri Mar 02, 2007 8:57 pm

How to make a loop?

Post by pello » Sat Mar 03, 2007 6:08 pm

Hi at all, this estension for firefox is wonderful!

I try to search italian support but i didn't find, so sorry for my bad english!

I make my own macro but i don't understand how to make a loop.
This is my code:

Code: Select all

VERSION BUILD=5200814 RECORDER=FF
SET !VAR1 1
TAB T=1
TAB CLOSEALLOTHERS
URL GOTO=localhost/portal/
WAIT SECONDS=1
TAG POS=1 TYPE=INPUT:IMAGE FORM=NAME:formular ATTR=VALUE:Login
WAIT SECONDS=1
SET !LOOP 499 '**<-- I want to make a loop of 499 cycle from here
FRAME F=1
TAG POS=1 TYPE=A ATTR=TXT:Team
FRAME F=2
TAG POS=1 TYPE=INPUT:TEXT FORM=ACTION:index.php? ATTR=NAME:stats CONTENT=1
TAG POS=1 TYPE=INPUT:TEXT FORM=ACTION:index.php? ATTR=NAME:system CONTENT={{!LOOP}} '**<-- This var must be the value of the loop
WAIT SECONDS=3
TAG POS=1 TYPE=INPUT:SUBMIT FORM=ACTION:index.php? ATTR=VALUE:Vai '<--** To here
WAIT SECONDS=1
Is it possible to make?

Thank you for your help.
Hannes, Tech Support

Post by Hannes, Tech Support » Mon Mar 05, 2007 4:18 pm

Hello,

for most loops, you should put the looping into a script and call iMacros via the command line.

But in some cases, the build-in !LOOP variable is enough.

Here's an example that enters the keywords test1, test2, test3, etc to the amazon search form:

Code: Select all

VERSION BUILD=5220125
TAB T=1
TAB CLOSEALLOTHERS
URL GOTO=http://www.amazon.com/
SIZE X=801 Y=602
TAG POS=1 TYPE=INPUT:TEXT FORM=NAME:site-search ATTR=ID:twotabsearchtextbox CONTENT=test{{!LOOP}}
TAG POS=1 TYPE=INPUT:IMAGE FORM=NAME:site-search ATTR=NAME:Go&&VALUE:Go
'Comment: New page loaded 
Concerning your script: SET !LOOP tells iMacros which value to start with. The end is given by the number next to the "Loop"-Button in the iMacros browser.


Hannes

Hannes
pello
Posts: 2
Joined: Fri Mar 02, 2007 8:57 pm

Post by pello » Mon Mar 05, 2007 5:34 pm

Ok, thank you for your help!.
Post Reply