start typing when the macro ends

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 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
mastikhor.maddy
Posts: 18
Joined: Mon Jul 30, 2018 8:30 pm

start typing when the macro ends

Post by mastikhor.maddy » Wed Jun 24, 2020 8:29 am

Google Chrome Version 81.0.4044.138 (Official Build) (64-bit)
IMACROS VERSION BUILD=1005 RECORDER=CR
using the free version of imacros on win 10 x64

This is the macro i use

SET !ERRORIGNORE NO
TAG POS=1 TYPE=BUTTON ATTR=TXT:Place<SP>selling<SP>price
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellAmount CONTENT=1
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT=CLEAR

I want to able to start typing in the sellPrice box when the macro ends
I have to manually click in the box to focus the keyboard cursor on it before start typing in it, is there a way to focus the keyboard cursor in the ID:sellPrice at the end of the macro ?
chivracq
Posts: 9494
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: start typing when the macro ends

Post by chivracq » Wed Jun 24, 2020 3:11 pm

mastikhor.maddy wrote:
Wed Jun 24, 2020 8:29 am

Code: Select all

Google Chrome Version 81.0.4044.138 (Official Build) (64-bit)
IMACROS VERSION BUILD=1005 RECORDER=CR
using the free version of imacros on win 10 x64[code]

This is the macro i use 

[code]SET !ERRORIGNORE NO
TAG POS=1 TYPE=BUTTON ATTR=TXT:Place<SP>selling<SP>price
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellAmount CONTENT=1
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT=CLEAR 
I want to able to start typing in the sellPrice box when the macro ends
I have to manually click in the box to focus the keyboard cursor on it before start typing in it, is there a way to focus the keyboard cursor in the ID:sellPrice at the end of the macro ?

Hum..., I'm a bit surprised to see that you are still at CR81...? How do you "manage" to prevent CR from updating itself...? :o

It is possible, and I do it myself..., (I'm still at CR76 actually), but it is rather very cumbersome to "achieve" and I would think only "reserved" for "pretty Advanced" Users and you need to be "very motivated" to prevent CR from updating, ah-ah...!, with Registry Hacks and Firewall Rules, but you didn't "sound" like being a very Technical Home User, until now from your previous Threads, I would think... :o

... Unless you work for some Company and CR is managed by some GPO from your IT-Dept, but I don't really "see" why they would keep CR at v81 as all CR Versions are usually only Security Updates..., especially "now" in this Corona/COVID19 "Time" and many People working remotely from Home... :o

Adding to the "Confusion" is that the iMacros 'FREE' Version is "FREE" for Home Users, Business Users are "supposed" to get a 'PE' License...
Not that I/we really care on the Forum, if (Business) Users are buying a License, as the Forum is (Advanced) Users helping Users, so we don't really care if "the Company" is selling Licenses or not, but hum..., just curious as how and why you are still at CR81...? :wink:

>>>

Then OK, back to your Thread/Scenario..., and yep-yep-yep...!, I completely understand your Scenario and what you want... :P

OK..., I have a very bad Internet Connection since a few days (big Hassle with my Int. Provider, so I'm using some WiFi AP from some befriended Neighbour, but it doesn't work very well), and I cannot do any Search on the Forum, but we had this very same Qt/Scenario in one Thread a few years ago, that ended up with one or more Solution(s)...
=> Search the Forum on "focus" as Search Keyword... And myself + other Advanced User @iimfun had participated in that Thread... (And the Thread is probably from 2017, I think...) Post a direct Link, once you've found it...

>>>

OK, I've already lost Internet Co. since I started to type, not sure when I'll be able to post this Reply, and I probably won't be able to edit my Post if I notice some Typo(s) afterward... :(
- (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...
mastikhor.maddy
Posts: 18
Joined: Mon Jul 30, 2018 8:30 pm

Re: start typing when the macro ends

Post by mastikhor.maddy » Wed Jun 24, 2020 7:12 pm

Google Chrome Version 83.0.4103.116 (Official Build) (64-bit)
i just copy pasted cim from a previous post of mine i thought it wont make any difference or u would even notice

is this the one ? http://forum.imacros.net/viewtopic.php? ... 971#p75613
i struggled to understand how
mastikhor.maddy
Posts: 18
Joined: Mon Jul 30, 2018 8:30 pm

Re: start typing when the macro ends

Post by mastikhor.maddy » Sat Jun 27, 2020 12:20 pm

just to add a bit i dont want imacros to input anything in the sellPrice box, as soon as the macro ends i want the keyboard cursor in that field blinking and any numbers thats i enter in keyboard should entered in the box after clearing the box which is the last line of the macro
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT=CLEAR
chivracq
Posts: 9494
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: start typing when the macro ends

Post by chivracq » Sun Jun 28, 2020 3:23 am

mastikhor.maddy wrote:
Wed Jun 24, 2020 7:12 pm
Google Chrome Version 83.0.4103.116 (Official Build) (64-bit)
i just copy pasted cim from a previous post of mine i thought it wont make any difference or u would even notice

is this the one ? http://forum.imacros.net/viewtopic.php? ... 971#p75613
i struggled to understand how

"I wouldn't even notice"
=> In your "Dreams", ah-ah...! :roll: , I don't ask Users to mention their FCI (and not "CIM" (= "Config Info Missing")) "for Fun", but I (always) need that Info to avoid several Layers of if+if+if+if when answering/trying to help...

[iMacros Add-on + Versions [+ 'Free'/'PE'/'Trial'/'Pro'/'Ent']] x [Browser + Versions] x [OS + Types + Versions/Builds] gives a 4D and sometimes a 5D Matrix where iMacros Commands and Functionality have always been supported/not supported, get broken etc by any Update of any of the 3 (main) Vectors...
+ Looping + Launching from a '.bat' File + '.iim'/'.js'/'.vbs' are also extra Vectors that each time add an extra Dimension to that "nD" Matrix, and all those "Parameters" are all on the "Client" Side, every Web-Site is also different and also brings "a few" extra "Parameters"... :idea:

+ I guess I automatically "profile" Users on the Quality of their Posts/Threads, Technical Skills, "Creativity", Care for Details, and their "Will" to learn and try to find a Solution by themselves, ah-ah...! :P

"is this the one ?"
=> Yeah well, unless you found (m)any other Thread(s) about some Input Field getting the "Focus", + from 2017, + with Posts from @chivracq + @iimfun in that Thread..., then of course, that's "the one", ah-ah...! :twisted:

>>>
mastikhor.maddy wrote:
Sat Jun 27, 2020 12:20 pm
just to add a bit i dont want imacros to input anything in the sellPrice box, as soon as the macro ends i want the keyboard cursor in that field blinking and any numbers thats i enter in keyboard should entered in the box after clearing the box which is the last line of the macro

Code: Select all

TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT=CLEAR

Yeah-yeah, I've completely understood what you want..., but hum, I don't know..., you need to dig a bit in that other Thread, I don't remember "everything", I see I had provided a Proof of Concept from one of the Demos, I don't remember what it was supposed to do exactly, you didn't provide any URL of your Site, so/and I can't do any Testing, even on the Demo, I still have a shitty Internet Connection, it took me hours just to load this simple "Post a Reply" Page and I'll probably have to try 30 times before that Reply actually gets posted... :|

Oh ja...!, and stg else, I remember I also had some other "Ideas" at that time, that I never mentioned, because the @OP didn't really follow up anymore after 2 Posts in that Thread..., and that was using the 'EVENT' Mode, with Keyboard Tabulation (= Tab Sequence), or maybe just finishing the Script with a Click inside that Input Element..., + Inputting some "fake" mini-Content in that Input Field, like just a Dot ('.'), from the 'TAG' or the 'EVENT' Mode, and deleting it from the 'EVENT' Mode..., that could also work..., but I don't remember if I had actually tested/tried those..., but that shouldn't be very difficult to test... :idea:
- (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...
mastikhor.maddy
Posts: 18
Joined: Mon Jul 30, 2018 8:30 pm

Re: start typing when the macro ends

Post by mastikhor.maddy » Wed Jul 08, 2020 3:15 pm

so i figured out what promt is via this vid youtube.com/watch?v=q4hbB7Mb5As
and tried this
SET !ERRORIGNORE NO
TAG POS=1 TYPE=BUTTON ATTR=TXT:Place<SP>selling<SP>price
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellAmount CONTENT=1
prompt <SP>Selling<SP>Price PRICE
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT={{PRICE}}

but the macro freezes and the after min or soo error pops up
FreewareLimit: Freeware version limit exceeded: user defined variables not allowed. Maximum number of variables is 3, line: 5
chivracq
Posts: 9494
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: start typing when the macro ends

Post by chivracq » Wed Jul 08, 2020 4:24 pm

mastikhor.maddy wrote:
Wed Jul 08, 2020 3:15 pm
so i figured out what promt is via this vid youtube.com/watch?v=q4hbB7Mb5As
and tried this

Code: Select all

SET !ERRORIGNORE NO
TAG POS=1 TYPE=BUTTON ATTR=TXT:Place<SP>selling<SP>price
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellAmount CONTENT=1
prompt <SP>Selling<SP>Price PRICE
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT={{PRICE}}
but the macro freezes and the after min or soo error pops up
FreewareLimit: Freeware version limit exceeded: user defined variables not allowed. Maximum number of variables is 3, line: 5

Hum, all Videos on 'YouTube' about iMacros are all a bit "Fake"/Low Quality/Click-Bait, ah-ah...! :shock:
You don't need a Video on 'YT' to understand how the 'PROMPT' Command works, it's 20 times better explained in the Wiki, I would think... :idea:

But hum, I can't check this one, I have a very bad Internet Connection, 'YT' doesn't work at all anymore since a few weeks on 'Pale Moon' (v26.3.3), my Default Browser, even on FF55, I can't load the "full" Page, and trying to download the Video stops after a few Mb's, but if I am correct, I had already checked that Video once, and the same YT User had a few Tutorials about iMacros, all very low Quality and simply reading the Wiki and replaying the Demos... + Can't spell correctly "iMacros" + "Firefox" + "Mozilla" one single time, ah-ah...!

>>>

So, hum, then you would go for an Input 'PROMPT' to get the Focus... Hum, OK, why not, that's not a bad Idea indeed..., I only "hope" that 'Enter' works from the Keyboard without having to click on 'OK', the 'PROMPT' Command was pretty buggy in v10.0.5 for CR (and v10.0.2 for FF) when I had tested it a bit in those 2 Versions...

>>>

But OK, anyway... Then well, yep, the RuntimeError you are getting is completely normal, if/as you are using any of the 'Free' Versions, let me check your FCI..., => v10.0.5 for CR 'Free', User Defined Vars are not supported in the 'Free' Versions, you can only use "!VAR[1-3]".
You need to get the 'PE' Version if you "absolutely" want to call your Var "PRICE"..., ah-ah...! :|
- (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...
mastikhor.maddy
Posts: 18
Joined: Mon Jul 30, 2018 8:30 pm

Re: start typing when the macro ends

Post by mastikhor.maddy » Mon Jul 13, 2020 12:34 am

the var1 worked
final code :

SET !ERRORIGNORE NO
TAG POS=1 TYPE=BUTTON ATTR=TXT:Place<SP>selling<SP>price
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellAmount CONTENT=1
prompt <SP>Selling<SP>Price !VAR1
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT={{!VAR1}}
chivracq
Posts: 9494
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: start typing when the macro ends

Post by chivracq » Mon Jul 13, 2020 1:08 am

mastikhor.maddy wrote:
Mon Jul 13, 2020 12:34 am
the var1 worked
final code :

Code: Select all

SET !ERRORIGNORE NO
TAG POS=1 TYPE=BUTTON ATTR=TXT:Place<SP>selling<SP>price
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellAmount CONTENT=1
prompt <SP>Selling<SP>Price !VAR1
TAG POS=1 TYPE=INPUT:NUMBER ATTR=ID:sellPrice CONTENT={{!VAR1}}

Yep, very good...! And Congrats on finding the/a Solution by yourself...! :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