set imacros when change my id

Discussions and Tech Support related to the iMacros Firefox Add-on, including the built-in Javascript scripting interface for playing .js files.

Moderators: Community Moderators, iMacros Moderators

Forum rules
Before asking a question or reporting an issue:
1. Please review the list of FAQ's.
2. Use the Google search box (at the top of each forum page) to see if a similar problem or question has already been addressed. This will search the entire contents of the forums as well as the iMacros Wiki.
3. We can respond much faster to your posts if you include the following information:

CLICK HERE FOR IMPORTANT INFORMATION TO INCLUDE IN YOUR POST

Answering your own posts (e.g. attempting to "bump" your topic) drops your topic from the list of unanswered threads, so it may actually receive less views.

set imacros when change my id

by nosequepensar on Tue Nov 14, 2017 5:43 pm

i'm having one problem because the id always change but it always start by a letter like:
Code: Select all
TAG POS=1 TYPE=A ATTR=ID:A*
TAG POS=1 TYPE=A ATTR=ID:B*
TAG POS=1 TYPE=A ATTR=ID:a*

it exists some way to include all the letters at the first testing with each one i mean if the button start with the letter A and if not with the other letters to press the button with the correct id.
It's there some way to get this goal?
nosequepensar
 
Posts: 5
Joined: Tue Nov 14, 2017 3:08 pm

Re: set imacros when change my id

by nosequepensar on Tue Nov 14, 2017 6:46 pm

i think the only way is using javascript.
Code: Select all
var string = '';
var letters = ['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','w','x','y','z','A','B','C','D','E','F','G','H','I','J','K','L','M','N','Ñ','O','P','Q','R','S','T','U','V','W','X','Y','Z'];
var init_macro = "CODE:";
init_macro += "VERSION BUILD=9052613" + "\n";
init_macro += "SET !ERRORIGNORE YES" + "\n";
for(i = 0; i < 54; i++){
string += letters[i];

init_macro += "TAG POS=1 TYPE=A ATTR=letters{{string}}*";
iimPlay(init_macro);
}
nosequepensar
 
Posts: 5
Joined: Tue Nov 14, 2017 3:08 pm

Re: set imacros when change my id

by chivracq on Wed Nov 15, 2017 10:23 am

nosequepensar wrote:i'm having one problem because the id always change but it always start by a letter like:
Code: Select all
TAG POS=1 TYPE=A ATTR=ID:A*
TAG POS=1 TYPE=A ATTR=ID:B*
TAG POS=1 TYPE=A ATTR=ID:a*

it exists some way to include all the letters at the first testing with each one i mean if the button start with the letter A and if not with the other letters to press the button with the correct id.
It's there some way to get this goal?

:roll:
nosequepensar wrote:i think the only way is using javascript.
Code: Select all
var string = '';
var letters = ['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','w','x','y','z','A','B','C','D','E','F','G','H','I','J','K','L','M','N','Ñ','O','P','Q','R','S','T','U','V','W','X','Y','Z'];
var init_macro = "CODE:";
init_macro += "VERSION BUILD=9052613" + "\n";
init_macro += "SET !ERRORIGNORE YES" + "\n";
for(i = 0; i < 54; i++){
string += letters[i];

init_macro += "TAG POS=1 TYPE=A ATTR=letters{{string}}*";
iimPlay(init_macro);
}

8)

Hum, wondering what that 27th Letter in the Alphabet is btw...!? :?
- (F)CIM = (Full) Config Info Missing: iMacros + Browser + OS with all 3 Versions...
- I usually don't even read the Question if that (required) Info is not mentioned...
- Script & URL usually help a lot for a more "educated" Help...
chivracq
 
Posts: 6490
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)


Return to iMacros for Firefox

Who is online

Users browsing this forum: Bing [Bot] and 7 guests

-->