Is there any limitation for function iimPlay()?

Discussions and Tech Support related to the iMacros Firefox Add-on, including the built-in Javascript scripting interface for playing .js files.
Forum rules
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
ccg2312
Posts: 5
Joined: Fri Jan 09, 2009 2:05 am

Is there any limitation for function iimPlay()?

Post by ccg2312 » Sun Jan 11, 2009 2:54 am

Every time I run my JavaScript(it will take a lot of Runtime Error messages of "TXT: was not found") in iMacros, the program will not continue for a while. I see the "iMacros.log", the log records more than 1200 "Play started" lines and there is not any error or warnning message. Is there any limitation for function iimPlay?
dharmendra2000
Posts: 214
Joined: Fri Jul 04, 2008 1:28 pm
Location: Ahmedabad
Contact:

Re: Is there any limitation for function iimPlay()?

Post by dharmendra2000 » Mon Jan 12, 2009 6:14 am

I think you are having some other problem!!
Can you please post your Java Script and HTML, I will try to solve your problem.
ccg2312
Posts: 5
Joined: Fri Jan 09, 2009 2:05 am

Re: Is there any limitation for function iimPlay()?

Post by ccg2312 » Mon Jan 12, 2009 9:43 am

dharmendra2000 wrote:I think you are having some other problem!!
Can you please post your Java Script and HTML, I will try to solve your problem.
Hello dharmendra2000:

My code is a little huge, but this problem can be reproduced with a piece of simple code below.

Run the JavaScript code below and Pause/Continue several times, and it may hang. It looks like "Thread DeadLock", I guess.

And another problem is, this infinite loop may not be stopped by pressing stop button. Even if I press stop button several times and it looks like stop, the play button is still disable. After stopping loop and closing firefox, firefox may sometimes crash or hang in the memory.

Code: Select all

iimPlay("CODE: SET !ERRORIGNORE NO");

function loop() {
    while(true) {
        var iret = iimPlay( "CODE:TAG POS=1 TYPE=A ATTR=TXT:Hemingway");
    }
}

while (true) {
    loop();
}
additional001
Posts: 175
Joined: Sun Jul 06, 2008 3:24 am

Re: Is there any limitation for function iimPlay()?

Post by additional001 » Wed Jan 14, 2009 8:00 am

I can tell you that when you STOP a JavaScript macro... and its running any type of iMacro code... it will cause you not to be able to play any other type of macro.

The only way around this I have found(for a WindowsXP user) is to CTRL+ALT+DEL and force the firefox.exe to be closed. That much is not because of your code it is a problem with iMacros.

If you showsteps... or in some cases are fast enough... and stop it while it is processing JS (like in the case of a for loop or if else statement) it shouldn't lock up.

Yeah it's very annoying... but let's hope that Tech Support is on the job.
ccg2312
Posts: 5
Joined: Fri Jan 09, 2009 2:05 am

Re: Is there any limitation for function iimPlay()?

Post by ccg2312 » Wed Jan 14, 2009 9:34 am

ccg2312 wrote:

Code: Select all

iimPlay("CODE: SET !ERRORIGNORE NO");

function loop() {
    while(true) {
        var iret = iimPlay( "CODE:TAG POS=1 TYPE=A ATTR=TXT:Hemingway");
    }
}

while (true) {
    loop();
}
This code also can produces an another problem. If I open two windows of firefox, and play this code one by one, then the first thread will be hanged on when the second thread is running.

Thanks for anyone's concern. :)
Post Reply