Page 1 of 1

question ...

Posted: Sat Sep 24, 2005 8:57 pm
by viashino_bogofinado
how a make a macro for:
if tab t2 is open, wait 5 seconds

its possible ?

Posted: Sun Sep 25, 2005 1:47 am
by Tech Support
This is possible using the Scripting Interface. Can I ask what is the purpose of this function? This will help us to suggest the best solution.

Posted: Sun Sep 25, 2005 9:36 pm
by viashino_bogofinado
(my english is very limited)

i use the script interface of iopus, i want one script like:

tab t=1
url goto=<link1>
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
if tab t-2 is open (this function not exist in script interface)
wait 30 seconds
tab t=1
tab closeallothers
end if
url goto=<link2>
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
if tab t-2 is open (this function not exist in script interface)
wait 30 seconds
tab t=1
tab closeallothers
end if
url goto=<link3>
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
if tab t-2 is open (this function not exist in script interface)
wait 30 seconds
tab t=1
tab closeallothers
end if

and continue ... link4, 5, 6, 7, 8.... (i dont know number of links i need)

do you tell me a exemple for this script ?

(sorry the english, if you talk in portuguese, its more easy for me :¬P)

Posted: Mon Sep 26, 2005 1:37 pm
by Tech Support
Your English is muuuuch better than my Portugese :wink:

You can achieve the function you need by using the Scripting Interface:

Example: Macro1 looks like:
tab t=1
url goto=<link1>
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
TAB T=2

Your script would look like

i = iim1.iimPlay ("macro1")
if i <0 then
msbox "tab2 not found!"
else
msbox "tab 2 open!"
endif

Basically you check if the TAB T=2 command returns an error (= no tab 2 present) or if TAB T=2 switches to tab 2 without error (=> tab 2 exists)

Posted: Mon Sep 26, 2005 3:54 pm
by viashino_bogofinado
this is in the "edit script" in the internet macros browser ?
i not have sucess with this ...

my script is:

TAB T=1
SET !ERRORIGNORE YES
URL GOTO=https://mysite/1
TAB T=1
TAB CLOSEALLOTHERS
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
WAIT SECONDS=18
TAB T=1
URL GOTO=https://mysite/2
TAB CLOSEALLOTHERS
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
WAIT SECONDS=18
TAB T=1
URL GOTO=https://mysite/3
TAB CLOSEALLOTHERS
TAG POS=1 TYPE=STRONG ATTR=HREF:javascript:
WAIT SECONDS=18

script continue...

exists a total of 9 pages to run in the same script,
only need wait if exists more of 1 tab , if not, dont wait, e goto the next step.

i know only mirc scripting, i confuze ... i am new in the iopus

please, post a how-to, is hard to undertand :¬P
more words = better to understand