0

i was wondering if it is possible to locate an element inside of an map marker container. If i go over it by inspecting it it returns me something like this and i cannot access inside of it.

<div id="map_markerContainer" style="position: relative; width: 100%; z-index: 1001; height: 100%;"></div>

I would like to be able to click the red dot in the picture, i couldn't find any solutions.

Here is the picture:

enter image description here

Fatih Enes
  • 75
  • 5

1 Answers1

1

I would go with pyautogui and Opencv in this case. What you would do is snip a screen shot of the area you would want to click then you would tell pyautogui to use Opencv to take a full screenshot and scan it for the snip you took. Then you would have pyautogui move the mouse to the screen shot and click it or you can just have it print out when you have found it.

Example

 login = pyautogui.locateOnScreen('Login.png', confidence=0.9)
    time.sleep(5)
    if login != None:
        pyautogui.moveTo(login)
        time.sleep(2)
        pyautogui.click()
Aaron Cloud
  • 315
  • 4
  • 15