Controlling Date Picker

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.

Controlling Date Picker

by ima123 on Sun Jan 29, 2017 3:32 am

VERSION BUILD=9030808 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1-page-ltd-historical-data
TAG POS=60 TYPE=SPAN ATTR=TXT:
WAIT SECONDS=3
TAG POS=12 TYPE=INPUT:TEXT ATTR=* CONTENT=01/01/2014
WAIT SECONDS=3
TAG POS=13 TYPE=INPUT:TEXT ATTR=* CONTENT=01/01/2015
WAIT SECONDS=3
TAG POS=1 TYPE=A ATTR=TXT:Eingabe

This works under (Firefox 51.0.1, Windows 7) apart from the last line.

How can I get the last line working without undesired reset of the selected date range to its default values?
ima123
 
Posts: 6
Joined: Sun Jan 29, 2017 3:15 am

Re: Controlling Date Picker

by chivracq on Sun Jan 29, 2017 5:23 am

ima123 wrote:
Code: Select all
VERSION BUILD=9030808 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1-page-ltd-historical-data
TAG POS=60 TYPE=SPAN ATTR=TXT:
WAIT SECONDS=3
TAG POS=12 TYPE=INPUT:TEXT ATTR=* CONTENT=01/01/2014
WAIT SECONDS=3
TAG POS=13 TYPE=INPUT:TEXT ATTR=* CONTENT=01/01/2015
WAIT SECONDS=3
TAG POS=1 TYPE=A ATTR=TXT:Eingabe


This works under (Firefox 51.0.1, Windows 7) apart from the last line.

How can I get the last line working without undesired reset of the selected date range to its default values?

This one seems to work for me, using a mix of 'TAG' and 'EVENT' Modes:
Code: Select all
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1-page-ltd-historical-data

'Select Dates:
'EVENT TYPE=CLICK SELECTOR="#datePickerIconWrap>SPAN" BUTTON=0
TAG POS=60 TYPE=SPAN ATTR=TXT:

'Start Date:
TAG POS=12 TYPE=INPUT:TEXT ATTR=* CONTENT=""
EVENTS TYPE=KEYPRESS SELECTOR="#startDate" CHARS="01/01/2014"
WAIT SECONDS=1

'End Date:
TAG POS=13 TYPE=INPUT:TEXT ATTR=* CONTENT=""
EVENTS TYPE=KEYPRESS SELECTOR="#endDate" CHARS="01/01/2015"
WAIT SECONDS=1

'EVENT TYPE=CLICK SELECTOR="#applyBtn" BUTTON=0
TAG POS=1 TYPE=A ATTR=TXT:Eingabe
(Tested on iMacros for FF v8.8.2, Pale Moon v26.3.3 (=FF47), Win10-x64.)
- (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: 6474
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)

Re: Controlling Date Picker

by ima123 on Mon Dec 04, 2017 5:07 am

chivracq wrote:
ima123 wrote:
Code: Select all
VERSION BUILD=9030808 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1-page-ltd-historical-data
TAG POS=60 TYPE=SPAN ATTR=TXT:
WAIT SECONDS=3
TAG POS=12 TYPE=INPUT:TEXT ATTR=* CONTENT=01/01/2014
WAIT SECONDS=3
TAG POS=13 TYPE=INPUT:TEXT ATTR=* CONTENT=01/01/2015
WAIT SECONDS=3
TAG POS=1 TYPE=A ATTR=TXT:Eingabe


This works under (Firefox 51.0.1, Windows 7) apart from the last line.

How can I get the last line working without undesired reset of the selected date range to its default values?

This one seems to work for me, using a mix of 'TAG' and 'EVENT' Modes:
Code: Select all
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1-page-ltd-historical-data

'Select Dates:
'EVENT TYPE=CLICK SELECTOR="#datePickerIconWrap>SPAN" BUTTON=0
TAG POS=60 TYPE=SPAN ATTR=TXT:

'Start Date:
TAG POS=12 TYPE=INPUT:TEXT ATTR=* CONTENT=""
EVENTS TYPE=KEYPRESS SELECTOR="#startDate" CHARS="01/01/2014"
WAIT SECONDS=1

'End Date:
TAG POS=13 TYPE=INPUT:TEXT ATTR=* CONTENT=""
EVENTS TYPE=KEYPRESS SELECTOR="#endDate" CHARS="01/01/2015"
WAIT SECONDS=1

'EVENT TYPE=CLICK SELECTOR="#applyBtn" BUTTON=0
TAG POS=1 TYPE=A ATTR=TXT:Eingabe
(Tested on iMacros for FF v8.8.2, Pale Moon v26.3.3 (=FF47), Win10-x64.)


Now, I use iMacros for Chrome 8.4.4, and again I do not get it to work (also not when using the cited advice from chivracq):

Page to be read is now e.g.
https://de.investing.com/equities/1300- ... rical-data

'select historical time range
TAG POS=1 TYPE=DIV ATTR=ID:widgetFieldDateRange
WAIT SECONDS=5
TAG POS=1 TYPE=INPUT:TEXT ATTR=ID:startDate CONTENT=01/07/2017
WAIT SECONDS=5
TAG POS=R1 TYPE=INPUT:TEXT ATTR=ID:endDate CONTENT=31/12/2017
WAIT SECONDS=5

'download historical prices
TAG POS=R1 TYPE=A ATTR=TXT:EINGABE
WAIT SECONDS=5

Same question as in January 2017:
How can I get the last line working without undesired reset of the selected date range to its default values?
ima123
 
Posts: 6
Joined: Sun Jan 29, 2017 3:15 am

Re: Controlling Date Picker

by chivracq on Mon Dec 04, 2017 9:04 am

ima123 wrote:Now, I use iMacros for Chrome 8.4.4, and again I do not get it to work (also not when using the cited advice from chivracq):

Page to be read is now e.g.
https://de.investing.com/equities/1300- ... rical-data

Code: Select all
'select historical time range
TAG POS=1 TYPE=DIV ATTR=ID:widgetFieldDateRange
WAIT SECONDS=5
TAG POS=1 TYPE=INPUT:TEXT ATTR=ID:startDate CONTENT=01/07/2017
WAIT SECONDS=5
TAG POS=R1 TYPE=INPUT:TEXT ATTR=ID:endDate CONTENT=31/12/2017
WAIT SECONDS=5

'download historical prices
TAG POS=R1 TYPE=A ATTR=TXT:EINGABE
WAIT SECONDS=5


Same question as in January 2017:
How can I get the last line working without undesired reset of the selected date range to its default values?

You're welcome...! Oh...!, sorry, I thought you were saying a mini-Thanks...! Not impressed by the Follow-up, 10 months later...! :shock:

But OK, I had a look again at your Site/Script, and hum, nothing has changed on the Page, I would think, and the 'EVENT' Mode on the same Fields still works fine and reliably... (I only add some 'Ctrl^a' on the Date Fields to select the original Date for each to make sure the "new" Date replaces it...):
Code: Select all
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1300-smiles-ltd-historical-data

'Open Date Picker:
EVENT TYPE=CLICK SELECTOR="#widgetFieldDateRange" BUTTON=0
'>
'Start Date:
'EVENT TYPE=CLICK SELECTOR="#startDate" BUTTON=0
EVENT TYPE=KEYPRESS SELECTOR="#startDate" CHAR="a" MODIFIERS="Ctrl"
EVENTS TYPE=KEYPRESS SELECTOR="#startDate" CHARS="01/07/2017"
'>
'End Date:
'EVENT TYPE=CLICK SELECTOR="#endDate" BUTTON=0
EVENT TYPE=KEYPRESS SELECTOR="#endDate" CHAR="a" MODIFIERS="Ctrl"
EVENTS TYPE=KEYPRESS SELECTOR="#endDate" CHARS="31/12/2017"
'>
'Click 'Eingabe' Button:
EVENT TYPE=CLICK SELECTOR="#applyBtn" BUTTON=0
(Tested on iMacros for FF v8.8.2, Pale Moon v26.3.3 (=FF47), Win10-x64.)
Hum, funny to notice that I still use the very same FCI like 10 months ago... 8)

And the 'EVENT' Mode is supported on iMacros for CR v8.4.4 as well (+ CR61/62/63), so it should work for you as well... 8)
- (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: 6474
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)

Re: Controlling Date Picker

by ima123 on Mon Dec 04, 2017 10:20 am

chivracq wrote:
ima123 wrote:Now, I use iMacros for Chrome 8.4.4, and again I do not get it to work (also not when using the cited advice from chivracq):

Page to be read is now e.g.
https://de.investing.com/equities/1300- ... rical-data

Code: Select all
'select historical time range
TAG POS=1 TYPE=DIV ATTR=ID:widgetFieldDateRange
WAIT SECONDS=5
TAG POS=1 TYPE=INPUT:TEXT ATTR=ID:startDate CONTENT=01/07/2017
WAIT SECONDS=5
TAG POS=R1 TYPE=INPUT:TEXT ATTR=ID:endDate CONTENT=31/12/2017
WAIT SECONDS=5

'download historical prices
TAG POS=R1 TYPE=A ATTR=TXT:EINGABE
WAIT SECONDS=5


Same question as in January 2017:
How can I get the last line working without undesired reset of the selected date range to its default values?

You're welcome...! Oh...!, sorry, I thought you were saying a mini-Thanks...! Not impressed by the Follow-up, 10 months later...! :shock:

But OK, I had a look again at your Site/Script, and hum, nothing has changed on the Page, I would think, and the 'EVENT' Mode on the same Fields still works fine and reliably... (I only add some 'Ctrl^a' on the Date Fields to select the original Date for each to make sure the "new" Date replaces it...):
Code: Select all
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
URL GOTO=https://de.investing.com/equities/1300-smiles-ltd-historical-data

'Open Date Picker:
EVENT TYPE=CLICK SELECTOR="#widgetFieldDateRange" BUTTON=0
'>
'Start Date:
'EVENT TYPE=CLICK SELECTOR="#startDate" BUTTON=0
EVENT TYPE=KEYPRESS SELECTOR="#startDate" CHAR="a" MODIFIERS="Ctrl"
EVENTS TYPE=KEYPRESS SELECTOR="#startDate" CHARS="01/07/2017"
'>
'End Date:
'EVENT TYPE=CLICK SELECTOR="#endDate" BUTTON=0
EVENT TYPE=KEYPRESS SELECTOR="#endDate" CHAR="a" MODIFIERS="Ctrl"
EVENTS TYPE=KEYPRESS SELECTOR="#endDate" CHARS="31/12/2017"
'>
'Click 'Eingabe' Button:
EVENT TYPE=CLICK SELECTOR="#applyBtn" BUTTON=0
(Tested on iMacros for FF v8.8.2, Pale Moon v26.3.3 (=FF47), Win10-x64.)
Hum, funny to notice that I still use the very same FCI like 10 months ago... 8)

And the 'EVENT' Mode is supported on iMacros for CR v8.4.4 as well (+ CR61/62/63), so it should work for you as well... 8)


In January I was very delighted that it did run on FF after your help! And I did not want to be impolite or ungreatful.

However, now I switched to CR, as I want to use the new FF...

I tried the cited code of today on FF 55.0.3. There it seems to work perfectly.

However, surprisingly the cited new code does not seems to run correctly on CR 62.0.3202.94 ?
ima123
 
Posts: 6
Joined: Sun Jan 29, 2017 3:15 am

Re: Controlling Date Picker

by chivracq on Mon Dec 04, 2017 4:41 pm

ima123 wrote:In January I was very delighted that it did run on FF after your help! And I did not want to be impolite or ungreatful.

However, now I switched to CR, as I want to use the new FF...

I tried the cited code of today on FF 55.0.3. There it seems to work perfectly.

However, surprisingly the cited new code does not seems to run correctly on CR 62.0.3202.94 ?

Hum, you seem to be right, (my) Script has "Difficulties" on CR indeed (iMacros for CR v8.4.4, CR62, Win10_x64), the 'Ctrl^a' with 'MODIFIERS' doesn't seem to work, I have a Workaround but all 'KEYS' are not supported on CR according to the Wiki, grrr...!, OK..., trying another Workaround with 'MOUSEMOVE' which doesn't really work very reliably again, re-grrr...!, then pfff..., it becomes Workaround on Workaround on Workaround, iMacros for CR used to be very Buggy until v8.4.4 which seemed to be finally a bit stable (even if I find Bugs for nearly every Actions I try each time I need to test a Script on CR, I'm surprised we don't get more Threads specific to CR...! :oops: ), but the 'EVENT' Mode looks very Buggy to me on CR, compared to FF..., I don't feel like trying to find some 3rd Level Workaround, you know it works fine on FF, that's your Workaround, or if you are lucky, some other Advanced User (@iimfun) might notice and jump into your Thread, and he uses CR as his Prod Browser, but I don't like CR and I (still) find iMacros for CR way too Buggy to investigate your Issue any further...
- (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: 6474
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)

Re: Controlling Date Picker

by ima123 on Mon Dec 04, 2017 9:28 pm

chivracq wrote:... but I don't like CR and I (still) find iMacros for CR way too Buggy to investigate your Issue any further...

OK, many thanks for your analyzes!
Now, for iMacros I will not update FF55.0.3 on a second computer until iMacros for FF57 or newer becomes available.
ima123
 
Posts: 6
Joined: Sun Jan 29, 2017 3:15 am

Re: Controlling Date Picker

by chivracq on Mon Dec 04, 2017 9:44 pm

ima123 wrote:
chivracq wrote:... but I don't like CR and I (still) find iMacros for CR way too Buggy to investigate your Issue any further...

OK, many thanks for your analyzes!
Now, for iMacros I will not update FF55.0.3 on a second computer until iMacros for FF57 or newer becomes available.

Yep..., stick to the "old" Version(s) that work(s) "correctly, my own "Prod" Env. is using iMacros for FF v8.8.2 which is quite an old Version now, and like you can see, I was already using this same Version, + the same Browser Version (PM v26.3.3) already 10 months ago when you had started this Thread... 8)

But I maintain as well another FCI more or less for the Forum, to follow a bit the "Standard" Trend, but still Stable (I never bothered for example to install v9.0.3 for FF), and this one is using iMacros for FF v8.9.7 for FF, + FF v55.0.3, and it works fine.
(There is only one mini-Bug with v8.9.7, since FF52, but v9.0.3 probably has it as well, (and it's not really an iMacros Bug, more that FF52 broke some Functionality that was working fine before, until FF51...), and "my" Bug is so "mini" that I'm the only one hitting it apparently as nobody else has ever encountered/confirmed it... (But I use iMacros in a few "extreme" Ways I guess, or "Creative" if you prefer, so I'm not too surprised actually, ah-ah...!))
- (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: 6474
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)

Re: Controlling Date Picker

by ima123 on Mon Dec 04, 2017 11:45 pm

chivracq wrote:Yep..., stick to the "old" Version(s) that work(s)

For me this is not without drawbacks as I need the newer FF for many other purposes.
However, this points to a further work araound:
As I detected now in a FF Forum, it seems to be possible to install two FF versions on a same PC.
ima123
 
Posts: 6
Joined: Sun Jan 29, 2017 3:15 am

Re: Controlling Date Picker

by chivracq on Tue Dec 05, 2017 6:56 am

ima123 wrote:
chivracq wrote:Yep..., stick to the "old" Version(s) that work(s)

For me this is not without drawbacks as I need the newer FF for many other purposes.
However, this points to a further work araound:
As I detected now in a FF Forum, it seems to be possible to install two FF versions on a same PC.

About FF (or CR) and/or iMacros Versions, yep..., depends on your "Requirements" and "Priority"..., iMacros is "leading" in my Case above the Browser and any other Add-ons I might be using...

You could have posted the Link to that "FF Forum", but yep, it has always been possible to have 2 or more different Versions of FF installed on the same PC, even if Mozilla made it a complete hassle from around FF40, especially when trying to update only one specific Install, but it is still possible..., and some "easy" Workaround is to use FF Portable, with all different Versions in their respective separate Folders... + for each Version, the iMacros Version that you want, and if you have different FF Profiles within one same Version, you can have different iMacros Versions for each Profile...
- (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: 6474
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)


Return to iMacros for Firefox

Who is online

Users browsing this forum: Baidu [Spider] and 16 guests

-->