Need to hit particular keyword using datasouce in imacros

Discussions and Tech Support related to website data extraction, screen scraping and data mining using iMacros.
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
pratiksha27.jain
Posts: 20
Joined: Wed Dec 28, 2016 7:24 am

Need to hit particular keyword using datasouce in imacros

Post by pratiksha27.jain » Thu Dec 29, 2016 11:09 am

IE :8.1
windows 7 enterprise
Imacro: 11.1.495.5175

*******************************
nba_snapshot.JPG
snapshot of webpage
Hi,

Attached is the snapshot of site am working on.

what i want to do is run imacro picking up the keywords from datasource and hit the keyword and extract data.

Like:

LnbA Admin-Cloud QA2
LnbA Admin - Dev1
LnbA Admin - Dev3

are the tags i want my imacro to click one by one (in each loop and extract data)

below is the code am using to hit a keyword once.

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=useridXX
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=passXX
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
'change the environment name as per the requirment
'TAG POS=1 TYPE=A ATTR=TXT:LnbA<SP>Dev<SP>-<SP>2


how am trying to loop it though (which is not working):


VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=userXX
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=passXX
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
TAG POS=1 TYPE=A ATTR=TXT:{{!COL1}}

********************
sharing the piece of xml
**************


<tr>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com:10225 ... o&app=LIFE" target="_blank")">
LnbA DInfomrmals</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
LnbA Dev</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=http://nbaldev2.axa-equitable.com:9080/nba/sso&app=LIFE" target="_blank")">
LnbA Dev-2</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com:10234 ... o&app=LIFE" target="_blank")">
LnbA Dev3</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com:10242 ... o&app=LIFE" target="_blank")">
LnbA Dev4</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa1.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
LnbA QA1</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa2.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
Legacy Migrated </a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa3.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
LnbA QA3</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalperf.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
LnbA QA4</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa5.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
LnbA QA5</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa6.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
LnbA QA6</a></td>

<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalist.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA IST</a></td>

<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa8.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA QA8</a></td>
<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalifeperfabs.axa-equitable.co ... o&app=LIFE" target="_blank")">LnbA ABS_PERFF</a></td>
<!-- <td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaluat2.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA UAT</a></td> -->


</tr>


I guess the last line is creating the problem.

any help is highly appreciable

Thank you.
chivracq
Posts: 9374
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Need to hit particular keyword using datasouce in imacro

Post by chivracq » Sat Dec 31, 2016 2:59 am

pratiksha27.jain wrote:

Code: Select all

IE :8.1
windows 7 enterprise
 Imacro: 11.1.495.5175
*******************************
nba_snapshot.JPG
Hi,

Attached is the snapshot of site am working on.

what i want to do is run imacro picking up the keywords from datasource and hit the keyword and extract data.

Like:

Code: Select all

LnbA Admin-Cloud QA2
LnbA Admin - Dev1
LnbA Admin - Dev3
are the tags i want my imacro to click one by one (in each loop and extract data)

below is the code am using to hit a keyword once.

Code: Select all

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=useridXX
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=passXX
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
'change the environment name as per the requirment
'TAG POS=1 TYPE=A ATTR=TXT:LnbA<SP>Dev<SP>-<SP>2
how am trying to loop it though (which is not working):

Code: Select all

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=userXX
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=passXX
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
[b]TAG POS=1 TYPE=A ATTR=TXT:{{!COL1}}[/b]
********************
sharing the piece of xml
**************

Code: Select all

<tr>			
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com:10225/nba/sso&app=LIFE" target="_blank")">
			LnbA DInfomrmals</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			LnbA Dev</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=http://nbaldev2.axa-equitable.com:9080/nba/sso&app=LIFE" target="_blank")">
			LnbA Dev-2</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com:10234/nba/sso&app=LIFE" target="_blank")">
			LnbA Dev3</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaldev.axa-equitable.com:10242/nba/sso&app=LIFE" target="_blank")">
			LnbA Dev4</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa1.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			LnbA QA1</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa2.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			Legacy Migrated </a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa3.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			LnbA QA3</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalperf.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			LnbA QA4</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa5.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			LnbA QA5</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa6.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">
			LnbA QA6</a></td>
			
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalist.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA IST</a></td>
			
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalqa8.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA QA8</a></td>
			<td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbalifeperfabs.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA ABS_PERFF</a></td>
			 <!-- <td><a href="/nbALoginModule/jsp/nbAPost.jsp?urld=https://nbaluat2.axa-equitable.com/nba/sso&app=LIFE" target="_blank")">LnbA UAT</a></td>  -->

			</tr>
I guess the last line is creating the problem.

any help is highly appreciable

Thank you.
Hum, your 2nd Script looks fine to me with:

Code: Select all

SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
TAG POS=1 TYPE=A ATTR=TXT:{{!COL1}}
What could play a role are maybe the Spaces in "LnbA Admin-Cloud QA2", even if I would expect iMacros to convert them automatically to "<SP>"...
Hum, 3 Things you can try:
1- Replace Spaces with "<SP>" in your DataSource (without the Double Quotes).
2- Enclose each Entry in your DataSource with Double Quotes.
3- Add Double Quotes in the 'TAG' Statement:

Code: Select all

TAG POS=1 TYPE=A ATTR=TXT:"{{!COL1}}"
But hum, it would help if you could mention if you get any RuntimeError and what that (exact!) Error is, "which is not working" is always vague...! :roll:

Other things you can try are to follow your '!COL1' Var with 'PROMPT':

Code: Select all

PROMPT _{{!COL1}}_
... before you want to use it in your 'TAG' Statement to make sure you didn't do any Typos in your DataSource, with Double Spaces for example, or leading/trailing Spaces...
You could as well use some Temp Var before using '{{!COL1}}' in your 'TAG' Statement in case stg goes wrong with Spaces:

Code: Select all

SET !VAR1 {{!COL1}}
PROMPT COL1:<SP>_{{!COL1}}_<BR>VAR1:<SP>_{!VAR1}}_
TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}
or:

Code: Select all

SET !VAR1 "{{!COL1}}"
PROMPT COL1:<SP>_{{!COL1}}_<BR>VAR1:<SP>_{!VAR1}}_
TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}
Stg that bothers me in your 2 Scripts is the 'ONDIALOG' Statement:

Code: Select all

ONDIALOG POS=1 BUTTON=NO
If it relates to the "incriminated" 'TAG' Statement with '!COL1' which triggers some Popup/Prompt Dialog, maybe iMacros "forgets" about it because of the DataSource Statements that you've placed in-between and you should rather place it directly before the 'TAG' Statement that will/might trigger it... :?

Wondering btw why you say each time "sharing the piece of xml", this is no 'XML' but 'HTML' afaik...?
And yep, that helps a bit to have a look at the HTML Structure of the Page/Element, but more useful if we (Advanced Users) need to do any Testing, is to upload some (zipped, Max 256Kb) HTML Saveas to your Thread, like I had already mentioned in your very first Thread... And it must be zipped ('.ZIP' / '.RAR'), you cannot upload '.TXT'/'.CSV' or '.HTM'/'.HTML' Files to the Forum... Images are directly accepted... (but we cannot use a Screenshot for any Testing...)

And try to use the ]QUOTE[ / ]CODE[ Forum Meta-Tags in your Posts like I do in my own Posts and Quotes, that makes your Posts much easier to read and to follow the Thread... :idea:
Last edited by chivracq on Mon Jan 02, 2017 3:09 pm, edited 2 times in total.
- (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...
pratiksha27.jain
Posts: 20
Joined: Wed Dec 28, 2016 7:24 am

Re: Need to hit particular keyword using datasouce in imacro

Post by pratiksha27.jain » Mon Jan 02, 2017 1:14 pm

thank you.

None of these is working
1- Replace Spaces with "<SP>" in your DataDource (without the Double Quotes).
2- Enclose each Entry in your DataSource with Double Quotes.
3- Add Double Quotes in the 'TAG' Statement;

I tried this code :

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=XXXXX
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=XXXXX
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
SET !VAR1 "{{!COL1}}"
PROMPT COL1:{{!VAR1}}
TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}

Have attached the dialogue box (value of VAR1),the error and the zipped source file

Please advise.
Attachments
IST2-error.JPG
The error am getting at last.
variable_value.JPG
dilaogue box with value for VAR1
variable_value.JPG (13.3 KiB) Viewed 4001 times
source_html.rar
source code
(2.32 KiB) Downloaded 157 times
chivracq
Posts: 9374
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Need to hit particular keyword using datasouce in imacro

Post by chivracq » Mon Jan 02, 2017 4:12 pm

pratiksha27.jain wrote:thank you.

None of these is working
1- Replace Spaces with "<SP>" in your DataDource (without the Double Quotes).
2- Enclose each Entry in your DataSource with Double Quotes.
3- Add Double Quotes in the 'TAG' Statement;

I tried this code :

Code: Select all

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=XXXXX
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=XXXXX
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
SET !VAR1 "{{!COL1}}"
PROMPT COL1:{{!VAR1}}
TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}
Have attached the dialogue box (value of VAR1),the error and the zipped source file

Please advise.
OK, I managed to have a look at your Page and this simple mini-Script works fine for me:

Code: Select all

VERSION BUILD=8820413 RECORDER=FX
TAB T=1
'URL GOTO=file:///D:/TEMP/iMacros/Temp/_Forum%20Cases/pratiksha27.jain/source_html.htm
TAG POS=A TYPE=A ATTR=TXT:LnbA<SP>Admin<SP>-<SP>IST2
TAB T=2
(Tested on iMacros for FF v8.8.2, Pale Moon v26.3.3 (=FF47), Win10-x64.)

But the Link is actually specified within a 'TD' Cell in the Table and I notice that the 'EXTRACT=TXT' and 'EXTRACT=HTM' on the 'A' and 'TD' Elements return slightly different Results with some leading Spaces/Tab/Soft Return at the 'TD' Level that the 'A' Level doesn't have (or that get trimmed by my Browser), and iMacros seems to be a little bit "confused" by both even if the Replay works for me. Maybe your older IE8 is not able to trim those leading Spaces automatically, then you can try adding a leading Wildcard to your 'TAG' Statement:

Code: Select all

TAG POS=1 TYPE=A ATTR=TXT:*{{!VAR1}}
Hum, and you should have kept the enclosing Underscores I had used in my previous Post to check/follow your '!COL1' Var with 'PROMPT', there is still a risk that your Data in your DataSource has some Trailing Space(s) even if that doesn't seem to be the case from your Screenshots...
- (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...
pratiksha27.jain
Posts: 20
Joined: Wed Dec 28, 2016 7:24 am

Re: Need to hit particular keyword using datasouce in imacro

Post by pratiksha27.jain » Thu Jan 19, 2017 12:46 pm

IE :11.0
windows 7 enterprise
Imacro: 11.1.495.5175

*************************************
Please find below the two codes (1 &2 ) and their respective outputs in attachment (output1 & output2)
********************************************************************

-------------
CODE :1
-----------------
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1

SET !DATASOURCE_LINE {{!LOOP}}

SET !VAR1 "{{!COL1}}"

PROMPT {{!VAR1}}

-----------------------

CODE2
---------

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=xxxx
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=xxxxx
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1

SET !DATASOURCE_LINE {{!LOOP}}

SET !VAR1 "{{!COL1}}"

TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}

------------------------------

TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}} doesnt work here

but If I write
TAG POS=1 TYPE=A ATTR=TXT:LnbA<SP>Cloud<SP>UAT

it works.

can someone please help.

also

the content of input of datasource file is as below :


"LnbA<SP>Cloud<SP>UAT"
"LnbA<SP>Admin<SP> -<SP> IST2"
"LnbA<SP>Admin<SP>-<SP>Dev2"
"LnbA<SP>Admin<SP>-<SP>IST2"
"Admin-Cloud<SP>UAT"
Attachments
output2.JPG
output of code2
output1.JPG
output of code1
output1.JPG (13.12 KiB) Viewed 3959 times
pratiksha27.jain
Posts: 20
Joined: Wed Dec 28, 2016 7:24 am

Re: Need to hit particular keyword using datasouce in imacro

Post by pratiksha27.jain » Tue Jan 24, 2017 12:11 pm

I got this working.



by simply changing highlighted line

SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
'TAG POS=1 TYPE=A ATTR=TXT:LnbA<SP>Admin-IST2
TAG POS=1 TYPE=A ATTR=TXT:{{!COL1}}



and data in csv be like :


LnbA Admin-Cloud UAT
LnbA Admin-Cloud QA2
LnbA Admin - IST2
LnbA Admin - QA7
LnbA Admin - Dev1
chivracq
Posts: 9374
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Need to hit particular keyword using datasouce in imacro

Post by chivracq » Tue Jan 24, 2017 1:24 pm

pratiksha27.jain wrote:

Code: Select all

IE :11.0
windows 7 enterprise
Imacro: 11.1.495.5175
*************************************
Please find below the two codes (1 &2 ) and their respective outputs in attachment (output1 & output2)
********************************************************************

-------------
CODE :1
-----------------

Code: Select all

SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1

SET !DATASOURCE_LINE {{!LOOP}}

SET !VAR1 "{{!COL1}}"

PROMPT {{!VAR1}}
-----------------------

CODE2
---------

Code: Select all

VERSION BUILD=11.1.495.5175
TAB T=1
TAB CLOSEALLOTHERS
SET !PLAYBACKDELAY 0.2
URL GOTO=http://20.17.236.130:7220/nbALoginModule/jsp/Links.jsp
'change login id as per the requirement
TAG POS=1 TYPE=INPUT:TEXT ATTR=NAME:uid CONTENT=xxxx
SET !ENCRYPTION NO
TAG POS=1 TYPE=INPUT:PASSWORD ATTR=NAME:password CONTENT=xxxxx
TAG POS=1 TYPE=INPUT:SUBMIT ATTR=NAME:submitLogin
ONDIALOG POS=1 BUTTON=NO
SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1

SET !DATASOURCE_LINE {{!LOOP}}

SET !VAR1 "{{!COL1}}"

TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}
------------------------------

Code: Select all

TAG POS=1 TYPE=A ATTR=TXT:{{!VAR1}}
doesnt work here

but If I write

Code: Select all

TAG POS=1 TYPE=A ATTR=TXT:LnbA<SP>Cloud<SP>UAT
it works.

can someone please help.

also

the content of input of datasource file is as below :

Code: Select all

"LnbA<SP>Cloud<SP>UAT"
"LnbA<SP>Admin<SP> -<SP> IST2"
"LnbA<SP>Admin<SP>-<SP>Dev2"
"LnbA<SP>Admin<SP>-<SP>IST2"
"Admin-Cloud<SP>UAT"
pratiksha27.jain wrote:I got this working.

by simply changing highlighted line

Code: Select all

SET !DATASOURCE C:\Users\pjain74\Desktop\macro\pollers_input.csv
SET !LOOP 1
SET !DATASOURCE_LINE {{!LOOP}}
'TAG POS=1 TYPE=A ATTR=TXT:LnbA<SP>Admin-IST2
[b]TAG POS=1 TYPE=A ATTR=TXT:{{!COL1}}[/b]
and data in csv be like :

Code: Select all

LnbA Admin-Cloud UAT
LnbA Admin-Cloud QA2
LnbA Admin - IST2
LnbA Admin - QA7
LnbA Admin - Dev1
Oh...!, good that you got it working...! Yep, it's all about Spaces, like I suspected from my first Reply... :wink:

Sorry I didn't reply anymore to your previous Post but your Posts are always a bit difficult to read/analyze as you don't use any Forum Formatting Meta-Tags although I've already asked you previously... :roll: , then I guess I didn't have the "Energy" to go digging again in your Thread at the time when you had posted, and I kind of forgot afterwards as new Threads probably came in...
But good that you managed to find a Solution..., and to share it... :D
- (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