Select Text from .csv file

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
dawidR
Posts: 13
Joined: Thu May 31, 2018 3:27 pm

Select Text from .csv file

Post by dawidR » Thu Mar 14, 2019 9:29 pm

Hello,
I was wondering if someone can help me with issue I am not able to resolve:

I would like to select text thats part of column 1 in my csv file. this is what works if I put number 72520 in the code FillInformations += "TAG POS=1 TYPE=B ATTR=TXT:72520" + "\n";

However I would like to use something like this:

FillInformations += "TAG POS=1 TYPE=B ATTR=TXT:CONTENT={{!COL1}}" + "\n";

Then this follows: (this part works)

FillInformations += "TAG POS=R1 TYPE=SPAN ATTR=TXT:[<SP>next<SP>]" + "\n"

thank you :)



iMacros for FF v9.0.3
FF v55.0.2
MacOS v10.13
iMacros for FF V8.9.7
FF v55.0.2
MacOS v10.13
chivracq
Posts: 8693
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Select Text from .csv file

Post by chivracq » Thu Mar 14, 2019 10:25 pm

dawidR wrote:
Thu Mar 14, 2019 9:29 pm
Hello,
I was wondering if someone can help me with issue I am not able to resolve:

I would like to select text thats part of column 1 in my csv file. this is what works if I put number 72520 in the code

Code: Select all

FillInformations += "TAG POS=1 TYPE=B ATTR=TXT:72520" + "\n";
However I would like to use something like this:

Code: Select all

FillInformations += "TAG POS=1 TYPE=B ATTR=TXT:CONTENT={{!COL1}}" + "\n";
Then this follows: (this part works)

Code: Select all

FillInformations += "TAG POS=R1 TYPE=SPAN ATTR=TXT:[<SP>next<SP>]" + "\n"
thank you :)

iMacros for FF v9.0.3
FF v55.0.2
MacOS v10.13
Okay..., and what is the Pb...? :?

This Line looks correct to me...:

Code: Select all

FillInformations += "TAG POS=1 TYPE=B ATTR=TXT:CONTENT={{!COL1}}" + "\n";
You didn't post your full Script, so I can't see how you've declared the DataSource, but that specific Line about using '{{!COL1}}' looks correct to me...

EDIT:
Arrrggghhh....!!! :oops: No-no-no!!, not correct indeed, you simply need to replace the exact part that you want to pull from the DataSource with the Var...
If the "original" 'TAG' Line doesn't use the 'CONTENT' Parameter, you don't need to add it...

So this one would be correct...:

Code: Select all

FillInformations += "TAG POS=1 TYPE=B ATTR=TXT:{{!COL1}}" + "\n";
- (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...
dawidR
Posts: 13
Joined: Thu May 31, 2018 3:27 pm

Re: Select Text from .csv file

Post by dawidR » Wed Mar 27, 2019 3:30 pm

I just tested this and worked like a charm! You are a life saver! thank you!
iMacros for FF V8.9.7
FF v55.0.2
MacOS v10.13
chivracq
Posts: 8693
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Select Text from .csv file

Post by chivracq » Wed Mar 27, 2019 3:45 pm

dawidR wrote:
Wed Mar 27, 2019 3:30 pm
I just tested this and worked like a charm! You are a life saver! thank you!
Yeah, "life saver", 2 weeks later... :shock: , you were not really "in a hurry"...! But OK, Thanks for the Feedback anyway... :|
- (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...
dawidR
Posts: 13
Joined: Thu May 31, 2018 3:27 pm

Re: Select Text from .csv file

Post by dawidR » Wed Mar 27, 2019 3:50 pm

my apologies, I will reply sooner next time. Work has been rather extremely busy for me and could not get to it right away. Sorry for not updating sooner.
iMacros for FF V8.9.7
FF v55.0.2
MacOS v10.13
Post Reply