Not sure if this is possible though but I'm trying to open a select2 and wanting to input some text so it can filter and eventually select an item.
VERSION BUILD=8810214 RECORDER=FX
TAB T=1
URL GOTO=http://ivaynberg.github.io/select2/
' selecting the select2 here '
Whenever I try to select the field it doesn't show up on imacro's.
I tried it out here: Example
Even with ' The basic ' it didn't show.
Any idea's?
I'm using Firefox.
Thanks in advance
Kind regards
EVENT TYPE=CLICK SELECTOR="HTML>BODY>DIV:nth-of-type(2)>SECTION:nth-of-type(3)>ARTICLE>DIV>P:nth-of-type(4)>DIV>A>SPAN:nth-of-type(2)>B" BUTTON=0
EVENT TYPE=CLICK SELECTOR="HTML>BODY>DIV:nth-of-type(4)>UL>LI:nth-of-type(3)>UL>LI>DIV" BUTTON=0
This code will click Arizona on the link you posted.
To make it changeable use JavaScript scripting and make the last digit in brackets changeable.
EVENT TYPE=CLICK SELECTOR="HTML>BODY>DIV:nth-of-type(2)>SECTION:nth-of-type(3)>ARTICLE>DIV>P:nth-of-type(4)>DIV>A>SPAN:nth-of-type(2)>B" BUTTON=0
EVENT TYPE=CLICK SELECTOR="HTML>BODY>DIV:nth-of-type(4)>UL>LI:nth-of-type({{!LOOP}})>UL>LI>DIV" BUTTON=0
Related
What's wrong with this code? It is write a test, but it doesn't want to press the enter key.
EVENTS TYPE=KEYPRESS SELECTOR="HTML>BODY>DIV:nth-of-type(3)>DIV:nth-of-type(3)>DIV>DIV:nth-of-type(2)>DIV:nth-of-type(4)>DIV>LABEL>INPUT" CHARS="test"
EVENT TYPE=KEYPRESS SELECTOR="HTML>BODY>DIV:nth-of-type(3)>DIV:nth-of-type(3)>DIV>DIV:nth-of-type(2)>DIV:nth-of-type(4)>DIV>LABEL>INPUT" KEY=13
Thanks
More details like site or htmlcode are helpful. Workaround is to press the 'Left Arrow' (=37) just before hitting the 'Enter' Key:
EVENTS TYPE=KEYPRESS SELECTOR="HTML>BODY>DIV:nth-of-type(3)>DIV:nth-of-type(3)>DIV>DIV:nth-of-type(2)>DIV:nth-of-type(4)>DIV>LABEL>INPUT" CHARS="test"
EVENTS TYPE=KEYPRESS SELECTOR="HTML>BODY>DIV:nth-of-type(3)>DIV:nth-of-type(3)>DIV>DIV:nth-of-type(2)>DIV:nth-of-type(4)>DIV>LABEL>INPUT" KEY="[37,13]"
iMacros script:
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
SET !DATASOURCE Address.csv
SET !LOOP 2
SET !DATASOURCE_LINE {{!LOOP}}
EVENT TYPE=CLICK SELECTOR="#text" BUTTON=0
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL1}}
EVENT TYPE=KEYPRESS SELECTOR="#text" KEY=13
Csv File:
Numbers
123
456
Hi, I am a beginner with iMacros. When I go to http://www.editpad.org/ and run the above iMacros script, it is supposed to grab each number from every row and input in the textfield on the site. The issue is, it only extracts the first character!
Output:
14
EDIT 1: I Think it's the "CHAR=" TAG that's causing this issue. Is there any other TAG I can use? Unfortunately, I'm having to use the key-press method of recording because the tag-targetting method doesn't work in my case. Which is why I can't use the "CONTENT=" TAG, which I know works well for sure.
EDIT 2: I know that there's a CHARS TAG, but when I use that, only a white-space is extracted for some reason
Only one character is extracted this way, but I came up with a workaround:
I split every digit into separate columns. (you can do this with tricks using notepad++. Simply copy a column from Notepad++ and paste into Excel)
Then I appended zeroes to the numbers with fewer digits, eg: 7 became 0007.
So in the end it looked something like this:
A B C D
0 0 0 7
0 1 2 3
etc.
Then within the iMacros script, I used multiple keypresses, each time a different Column:
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL1}}
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL2}}
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL3}}
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL4}}
That did it for me as it fulfilled the purpose of this script.
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
SET !DATASOURCE Address.csv
SET !LOOP 2
SET !DATASOURCE_LINE {{!LOOP}}
EVENT TYPE=CLICK SELECTOR="#text" BUTTON=0
EVENTS TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL1}}
EVENT TYPE=KEYPRESS SELECTOR="#text" KEY=13
Try this code. I replaced EVENT with EVENTS.
Maybe the .csv is bad created.
With the script of #user1744228:
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL1}}
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL2}}
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL3}}
EVENT TYPE=KEYPRESS SELECTOR="#text" CHAR={{!COL4}}
You can use this tool to create propper .csv files:
http://cetagram.co.nf/csv-file-creator/
It's a .csv file creator which puts the text in UTF-8 mode and creates out of it numbers or texts, which can be used for your macro
Try this code replaced EVENT with EVENTS and CHAR with CHARS
I want to know how to handle onchange event of dropdown in nsis installoptions .
Actually what I want to do is based on selection made on dropdown some text fileds should be polulated.
Take a look at http://nsis.sourceforge.net/Docs/nsDialogs/Readme.html#step-notify
Alternatively, could you move the dependent text fields onto the next page?
Enter does not select item in select element in inline edit and blocks double click.
Steps to reproduce:
Open
http://trirand.com/blog/jqgrid/jqgrid.html
in IE9
Select
Row Editing (new)
Input types
Double click in first row "Desktop computer"
to start inline edit
Click in "Ship via" column in first row FedEx fiel to open dropdown.
Press Down arrow key to select Intime
Press Enter
Observed:
FedEx appears in Ship Via column
Double click in this row not more starts inline edit
Expected:
Intime should appear
Double click should put row in inline edit mode again.
How to fix ?
I suggest to solve the problem like in the change. The idea is very easy. Is one change focus many required finalization actions can be done in the current control. For example in case of <select> the 'change' event will be fired, onfocusout will be called and popup menus (context menu or datepicker) will be closed and so on.
SO I suggest to add the line
$(ta).closest("tr.jqgrow").focus();
inside of 'keydown' event handler after the line. The results you can see on the demo.
Hey all, i am looking for a way to send a keypress letter/number to a textbox. The reason why i need this is that this textbox is a AutoComplete box that, when the user types, it displays a list of suggestions like google does.
However, for it to work, the user has to click in the box and type something. I can send any number/letter to the box i want using this code:
Private Sub Command_Click()
AutoComplete1.Text = "g"
End Sub
And it does put it into the textbox but it does not trigger the autocomplete list (the list has words like "good","great","pop","test"). Only when i click in the textbox and type "g" is the only time i get the "good","great" suggestions.
Is there a way to trigger this with the code i posted above?
Thanks!
David
Wouldn't
AutoComplete1.SetFocus()
SendKeys("g")
do that?
How about putting the code in the Key_Press event of the textbox instead of click event of the command button?
My guess would be to use Keyup event and fire the code that displays the list of suggestion if it isn't fired by the Keyup event itself