Closed asakre closed 5 years ago
Try using type step with [enter] as the text, for eg type identifier as my name[enter]
More details at - https://github.com/kelaberetiv/TagUI#steps-description
For complex keyboard automation, need to use SikuliX automation, more details below -
I tried the (type identifier as my name[enter]), but didn't work. I searched and found this link which has exactly what I need : https://www.rpa-sg.org/TagUI-Sikuli-Commands/type.php
I tried to run vision type(Key.ENTER) , but it hanged the flow.
This error usually happens when SikuliX is not set up properly. Check 2 things -
If you have download the packaged installation for your OS from this link https://github.com/kelaberetiv/TagUI#set-up
If you have installed Java JDK v8 (64-bit) or later for the SikuliX automation requirements. The link is found in the visual automation link in previous comment - http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
If above 2 things are checked, you can try again using keyboard step to natively control keyboard.
I have installed the package from the link above, and I've now installed JDK8, and restarted the PC, but still hanging at the vision type(Key.Enter) step. Any ideas ?
This is strange issue, have not encounter this. Look for the folder tagui\src\tagui.sikuli. There should be some log file there for Windows. When it hangs, check contents of the log file and paste here.
I think it is case sensitive. I changed it to vision type(Key.ENTER) , and it didn't hang. My problem is that it didn't simulate an "enter" press.
What I simply need is to enter an ID as shown below, which will filter the result to only show 1 result. My problem is selecting this one result.
click .chosen-single span type .chosen-search input as d1059 vision type(Key.Enter)
Any help would be appreciated.
I see.. Try using the keyboard step directly. Using vision step to control keyboard is the old way and harder because need to memorise the keywords. For this case it is only enter key, so try below -
try below see if it works for you, assuming pressing enter is how you normally select -
click .chosen-single span
type .chosen-search input as d1059[enter]
see if you can click inspect on the result so that you can select it directly using its ID or XPath
if you can't, try taking a snapshot of the selection and then visually click the selection by providing the snapshot as what to be selected. eg click selected.png
. If the selection text always changes, take the part of screen shot which does not change, for example the right side blue part.
The problem is that, when the robot types in the number, the text box strangely doesn't feel that any text has been typed in. If you see the screenshot below, if I typed this number by myself, it will be filtered as in screenshot 1 , while if robot types it, it will not be filtered (screenshot 2). This is making the issue complicated because now I even can't use Enter, arrow down, tab ..etc. Also I can't use any images or coordinates because the required selection is not filtered.
Screenshot 1 :
Screenshot 2 :
I tried Type and Enter along with Xpath, but nothing worked. Any help would be appreciated?
I see.. this looks like an unusual web control that does not work with the automated event triggers sent to Chrome. For such a case, the best option will be to use the visual automation mode directly.
Take an image snapshot of the text box, include the Select Doctor text so that TagUI can recognise that textbox from other textboxes on the screen. Save image as .png or .bmp format.
TagUI will click on the center of the snapshot in step 1. So make sure the snapshot image is taken so that clicking on the center of the image will trigger a mouse click in the textbox.
Use the following to visually click on the image and enter -
type textbox.png as d1059[enter]
If step 3 does not work try below -
click textbox.png
keyboard d1059[enter]
Thanks Kensoh, the image solution has worked.
I tried to run it in the background (i.e. without chrome) , but it didn't select a doctor. Does the image solution work if I will not use chrome ?
Oh I'm afraid not. The image solution only works if there is a real browser on the screen for the robot to use computer vision to find and then click / type onto the screen.
If your implementation strictly has to be invisible Chrome mode (headless or default PhantomJS), image solution cannot work. Your other option is using dom step to send custom JavaScript code to simulate the clicking and typing. The level of difficulty can be very hard depending on the website design, and hard for me to advise.
I don't have a problem if the browser is shown, but in such case, can I run more than one instance of this flow ? i.e. I want to initiate this flow multiple times in parallel. If not possiblr, I will check the DOM solution.
I see... TagUI is not designed to run in parallel. You can try installing TagUI to different directories and run in parallel, but you will probably run into errors. Because it has not been design for parallel runs.
I see. So are there any Free/Open source RPAs out there that could run parallel robots at the same time ? This is a required functionality.
I'm afraid I'm not aware of any that can do that. Even for paid commercial RPA tools, they run one session per laptop and use a central server to run multiple sessions by using multiple laptops.
You can search around for open-source load-testing tools. They are designed for parallel runs, but they may not work as expected because they do not replicate a real web browser such as Chrome.
Gracias Kensoh, la solución de imágenes ha funcionado.
Hi, how fixed this?
Thanks Kensoh, the image solution has worked.
Hi, How Fixed This?
Sorry @o3smartcities I was away the past few months - https://github.com/tebelorg/RPA-Python/issues/144
Yes the solution is above - https://github.com/kelaberetiv/TagUI/issues/504#issuecomment-512187840
It works by using visual automation to click on the dropdown, before using keyboard step to type into it.
I need to entersome data in a text/combo box , and simply press enter , as there are no buttons to submit here. Is there a way to add an "enter" press action ?