Replay if error ?

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
Doctordien
Posts: 1
Joined: Tue Apr 24, 2018 8:39 am

Replay if error ?

Post by Doctordien » Tue Apr 24, 2018 8:44 am

c

Hi guys, i'm completely a newbie.
I'm working on creating an iMacros script. Is there anyway to replay the previous step if error found ? My script works just fine except that sometimes the sever gets down which causes my script to stop playing ( it handles at that step without playing ) Note that I used SET ERROR IGNORE but it doesn't work, the script just stops playing.
I started to think on creating a java script with some if statements to replay the macros if errors found. However, I don't know much about java, can someone please help me generating the necessary code in this case ?
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Replay if error ?

Post by chivracq » Tue Apr 24, 2018 9:40 pm

Doctordien wrote:c

Hi guys, i'm completely a newbie.
I'm working on creating an iMacros script. Is there anyway to replay the previous step if error found ? My script works just fine except that sometimes the sever gets down which causes my script to stop playing ( it handles at that step without playing ) Note that I used SET ERROR IGNORE but it doesn't work, the script just stops playing.
I started to think on creating a java script with some if statements to replay the macros if errors found. However, I don't know much about java, can someone please help me generating the necessary code in this case ?
CIM...! :mrgreen: (Read my Sig...)

If you are "completely a newbie", then tja...!, you first need to read a bit of the Documentation and a few (relevant) Threads on the Forum, what you want sounds very "Legit" to me and you'll find many similar Threads on the Forum, so the Answer to your "Is there anyway to replay the previous step if error found ?" Qt is obviously a "YES of course...!", but your Post is completely vague at this moment without Script and URL... (and what you've tried and where you get stuck...) :idea:

We (Advanced Users) are here to help you but you need to "try your best" by yourself, then yep, we are here to help you if you "really" get stuck... 8)
- (F)CI(M) = (Full) Config Info (Missing): iMacros + Browser + OS (+ all 3 Versions + 'Free'/'PE'/'Trial').
- FCI not mentioned: I don't even read the Qt...! (or only to catch Spam!)
- Script & URL help a lot for more "educated" Help...
access2vivek
Posts: 69
Joined: Wed Dec 20, 2017 10:00 am
Location: New Delhi, India
Contact:

Re: Replay if error ?

Post by access2vivek » Sun Nov 04, 2018 12:41 pm

I think the following is what you are trying to do: -

var executed=true;

while(executed)
{
var code="CODE:SET !ERRORIGNORE YES\n";
code+="YOUR CODE THAT YOU WANT TO RUN"\n;
code+="YOUR CODE THAT YOU WANT TO RUN"\n;
.
.
.
code+="YOUR CODE THAT YOU WANT TO RUN"\n;
if(iimPlay(code)<0)
execute=false;
}

I believe this should help solve your problem. If not, do share your code and the URL so it is possible to get help.
Robust iMacros development with quick turnaround time. Drop an email at "access2content@gmail.com" with your project details.
Post Reply