save data in second column

Support for iMacros. The iMacros software is the unique solution for automating every activity inside a web browser, for data extraction and web testing.
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.
Post Reply
a2515125
Posts: 102
Joined: Tue Dec 06, 2016 3:37 am

save data in second column

Post by a2515125 » Tue Sep 11, 2018 9:42 am

FF52/imacros 8.9.7/windows 10


hey,

I already have urls data in first column....
and now I want to check if those urls is working or not

so my script is
if extract .TXT = "Sorry, this content isn't available right now", save its in second Column so that
I can clearly see which url on first column is not working after extracting.





Code: Select all


SET !EXTRACT_TEST_POPUP NO
SET !ERRORIGNORE YES
SET !TIMEOUT_STEP 0

SET !DATASOURCE url.csv
URL GOTO={{!COL1}}
WAIT SECONDS=2


TAG POS=1 TYPE=H2 ATTR=CLASS:uiHeaderTitle EXTRACT=TXT

SAVEAS TYPE=EXTRACT FOLDER=C:\Users\a2515125\Documents\iMacros\Datasources FILE=check_list.csv



chivracq
Posts: 7892
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: save data in second column

Post by chivracq » Tue Sep 11, 2018 12:58 pm

a2515125 wrote:

Code: Select all

FF52/imacros 8.9.7/windows 10
hey,

I already have urls data in first column....
and now I want to check if those urls is working or not

so my script is
if extract .TXT = "Sorry, this content isn't available right now", save its in second Column so that
I can clearly see which url on first column is not working after extracting.

Code: Select all

SET !EXTRACT_TEST_POPUP NO
SET !ERRORIGNORE YES
SET !TIMEOUT_STEP 0

SET !DATASOURCE url.csv
URL GOTO={{!COL1}}
WAIT SECONDS=2

TAG POS=1 TYPE=H2 ATTR=CLASS:uiHeaderTitle EXTRACT=TXT

SAVEAS TYPE=EXTRACT FOLDER=C:\Users\a2515125\Documents\iMacros\Datasources FILE=check_list.csv
A simple "SET !EXTRACT {{!COL1}}" before your 'EXTRACT' will include your '!COL1' in the 'SAVEAS... :idea:
- (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...
a2515125
Posts: 102
Joined: Tue Dec 06, 2016 3:37 am

Re: save data in second column

Post by a2515125 » Mon Sep 17, 2018 7:39 am

the problem is I do not want to change my original data in First column.........

I only want to save extract data in Second column......or Third column

is it possible to achieve? if possible.....how
chivracq
Posts: 7892
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: save data in second column

Post by chivracq » Mon Sep 17, 2018 8:01 am

a2515125 wrote:the problem is I do not want to change my original data in First column.........

I only want to save extract data in Second column......or Third column

is it possible to achieve? if possible.....how
Beh yep of course, you have complete Control over the '!EXTRACT' Var... which is what will be saved to your '.CSV' with the 'SAVEAS' Command...!
=> Use 'ADD !EXTRACT xxx' instead of 'SET !EXTRACT xxx'... :idea:

This is very "Basic" Knowledge of iMacros, mastered within 2 hours after discovering the "Tool", you've been using iMacros for 2 years now...! Come on...! :shock:
=> And use 'ADD !EXTRACT' in the correct order of course...! => After the 'EXTRACT' then, in case that was still not clear to you... :shock:
- (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: 7892
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: save data in second column

Post by chivracq » Sun Sep 30, 2018 3:22 am

Hum, saw you checking the Forum... And...?, did you manage to use 'SET' and 'ADD' in the "desired" Order to get to save the Data you wanted like you wanted it...? :?:
- (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...
Post Reply