Is it even possible to click a link using VbScript with Selenium?
Here is my script:
'connect to existing Chrome window just like WBGet()!
'Step 1. Start Chrome with command line: chrome.exe --remote-debugging-port=9222
'(Be sure to kill all running Chome windows that didn't start with --remote-debugging-port=9222)
Dim driver
Dim posts
IP_Port = "127.0.0.1:9222"
Set driver = CreateObject("Selenium.ChromeDriver")
driver.SetCapability "debuggerAddress",IP_Port
driver.Start
'qwerty = driver.FindElementsByXPath("//*").Count
'qwerty = driver.FindElementsByXPath("//*").Item(1).Attribute("textContent")
'qwerty = driver.FindElementsByXPath("//div[@class='next_in_queue_area']/div[@class='btn_next_in_queue btn_next_in_queue_trigger']").Item(1).text
'driver.FindElementsByXPath("//div[@class='next_in_queue_area']/div[@class='btn_next_in_queue btn_next_in_queue_trigger']").Item(1).ScrollIntoView
'qwerty = driver.FindElementsByXPath("//div[@class='next_in_queue_area']").Item(1).text
'driver.FindElementsByXPath("//div[@class='next_in_queue_area']").Item(1).ScrollIntoView
'driver.FindElementsByXPath("//div[@class='queue_actions_ctn']").Item(1).Click
'qwerty = driver.FindElementsByXPath("//div[@class='btn_next_in_queue btn_next_in_queue_trigger']").Item(1).text
'qwerty = driver.FindElementsByClass("btn_next_in_queue").Item(1).text
'driver.FindElementsByClass("btn_next_in_queue").Item(1).ScrollIntoView
'driver.FindElementsByXPath("(.//*[normalize-space(text()) and normalize-space(.)='Customize'])[1]/following::span[1]").Item(1).click
'driver.FindElementByXPath("//div[@class='btn_next_in_queue btn_next_in_queue_trigger']/div[@class='next_in_queue_content']/span").Click
'driver.FindElementByClass("btn_next_in_queue").Click
'driver.FindElementByXPath("//div[@class='btn_next_in_queue btn_next_in_queue_trigger']/div[@class='next_in_queue_content']/span").Click
'driver.FindElementsByXPath("//div[@class='btn_next_in_queue btn_next_in_queue_trigger']/div[@class='next_in_queue_content']/span").Item(1).Click
'driver.FindElementByXPath("//div[@class='btn_next_in_queue btn_next_in_queue_trigger']/div[@class='next_in_queue_content']/span").Click
MsgBox(driver.FindElementsByClass("btn_next_in_queue").Item(1).text)
I'm using VbScript with Selenium driver to connect to Chrome to click a link on Steam (https://store.steampowered.com/app/400280/Lizard/) - You have to be logged into steam, scroll down to "YOUR DISCOVERY QUEUE" and start the queue, then the button will appear.
Using the last line displays the correct info regarding the "Next in Queue" button, but when trying this:
driver.FindElementsByClass("btn_next_in_queue").Item(1).click does nothing and no error.