Cannot load "%SHAN" from CSV file

Discussions and Tech Support specific to the iMacros for Chrome extension.
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
ss9545
Posts: 3
Joined: Wed Oct 12, 2016 2:01 am

Cannot load "%SHAN" from CSV file

Post by ss9545 » Wed Oct 12, 2016 2:10 am

1. VERSION BUILD=844 RECORDER=CR
2. Windows 7 Professional SP1
3. Google Chrome Version 53.0.2785.143 m
4. Demo works fine
5. Not scripting
6. Didn't try on other website
7. Same macro and CSV file works OK on iMacros Browser

The record shows one of the CONTENT is "TAG POS=1 TYPE=SELECT ATTR=NAME:site CONTENT=%SHAN". Once I put "%SHAN" in CSV file and load with {{!COL8}}, Chrome replied "RuntimeError: Unable to select entry(ies) specified by: {{!COL8}}, line: 18".

Does anyone know how to solve this? Thanks!
chivracq
Posts: 9290
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Cannot load "%SHAN" from CSV file

Post by chivracq » Wed Oct 12, 2016 8:48 am

ss9545 wrote:

Code: Select all

1. VERSION BUILD=844 RECORDER=CR
2. Windows 7 Professional SP1
3. Google Chrome Version 53.0.2785.143 m
4. Demo works fine
5. Not scripting
6. Didn't try on other website
7. Same macro and CSV file works OK on iMacros Browser
The record shows one of the CONTENT is "TAG POS=1 TYPE=SELECT ATTR=NAME:site CONTENT=%SHAN". Once I put "%SHAN" in CSV file and load with {{!COL8}}, Chrome replied "RuntimeError: Unable to select entry(ies) specified by: {{!COL8}}, line: 18".

Does anyone know how to solve this? Thanks!
Yep, normal, like explained in the Wiki, the '%' Symbol must be outside your Var and you must put "SHAN" in your '.CSV':

Code: Select all

'TAG POS=1 TYPE=SELECT ATTR=NAME:site CONTENT=%SHAN // (Recorded.)
TAG POS=1 TYPE=SELECT ATTR=NAME:site CONTENT=%{{!COL8}}
iMacros for Firefox/Chrome Note:

When you use the $, % and # symbols with variables, the symbols must be outside the {{..}}, so that iMacros can see the variable type while parsing. This is just as in any other scripting language where you have to declare the type before usage:

This will not work in iMacros For Firefox or Chrome:

Code: Select all

 'Example on how NOT to it
 SET !VAR1 $*apple*
 TAG POS=1 TYPE=SELECT FORM=NAME:form1 ATTR=NAME:select1 CONTENT={{!VAR1}}
This works:

Code: Select all

 'Correct $,%,# usage
 SET !VAR1 *apple*
 TAG POS=1 TYPE=SELECT FORM=NAME:form1 ATTR=NAME:select1 CONTENT=${{!VAR1}}
- (F)CI(M) = (Full) Config Info (Missing): iMacros + Browser + OS (+ all 3 Versions + 'Free'/'PE').
- I don't even read the Qt if that (required) Info is not mentioned...!
- Script & URL help a lot for more "educated" Help...
Post Reply