<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic AutoIt Script how to interact with Chrome (login, copy text from a webpage into a box) in PAM Self-Hosted Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419590#M87625</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;With AutoIt I can interact with Internet Explorer, but when it comes with Chrome, the only way I found was with:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Support of Python (using selenium (pip install selenium/ from selenium import webdriver) )&lt;/LI&gt;&lt;LI&gt;or using direct Send("XYZ") to enter username and Send("{TAB}") ; &lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems I can't contact Chrome Directly like Internet Explorer, to search input field (by its ID) or extract an element (extract the text from the &amp;lt;h1 class="post-title"&amp;gt; element)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example &lt;A alt="https://practicetestautomation.com/practice-test-login/" href="https://practicetestautomation.com/practice-test-login/" target="_blank"&gt;https://practicetestautomation.com/practice-test-login/&lt;/A&gt; with AutoIT I can use Internet Explorer ( But for Chrome it seems impossibile to interact, unless I use python or a direct send)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to write the below script but with Chrome?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Create the COM object for Internet Explorer&lt;/P&gt;&lt;P&gt;Global $oIE = ObjCreate("InternetExplorer.Application")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Navigate to the URL&lt;/P&gt;&lt;P&gt;$oIE.Navigate("&lt;A alt="https://practicetestautomation.com/practice-test-login/" href="https://practicetestautomation.com/practice-test-login/" target="_blank"&gt;https://practicetestautomation.com/practice-test-login/&lt;/A&gt;")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Find the username input field (by its ID)&lt;/P&gt;&lt;P&gt;Local $oUsernameField = $oIE.document.getElementById("username")&lt;/P&gt;&lt;P&gt;If IsObj($oUsernameField) Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;$oUsernameField.value = "student" ; Enter your username here&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Username field not found!")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Exit&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Find the password input field (by its ID)&lt;/P&gt;&lt;P&gt;Local $oPasswordField = $oIE.document.getElementById("password")&lt;/P&gt;&lt;P&gt;If IsObj($oPasswordField) Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;$oPasswordField.value = "Password123" ; Enter your password here&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Password field not found!")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Exit&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Find and click the Submit button (by its ID)&lt;/P&gt;&lt;P&gt;Local $oSubmitButton = $oIE.document.getElementById("submit")&lt;/P&gt;&lt;P&gt;If IsObj($oSubmitButton) Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;$oSubmitButton.Click() ; Click the submit button&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Submit button not found!")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Exit&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Now, extract the text from the &amp;lt;h1 class="post-title"&amp;gt; element&lt;/P&gt;&lt;P&gt;Local $oTitleElement = $oIE.document.getElementsByClassName("post-title")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If IsObj($oTitleElement) And $oTitleElement.length &amp;gt; 0 Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;; Extract the text from the &amp;lt;h1 class="post-title"&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Local $sMessage = $oTitleElement.item(0).innerText&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;; Copy the extracted text to the clipboard&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;ClipPut($sMessage)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;; , display the copied text in a message box&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Success Message", "The message copied to clipboard is: " &amp;amp; @CRLF &amp;amp; $sMessage)&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Could not find the success message!")&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much&lt;/P&gt;</description>
    <pubDate>Tue, 09 Dec 2025 22:49:43 GMT</pubDate>
    <dc:creator>A.ElSheredi582594</dc:creator>
    <dc:date>2025-12-09T22:49:43Z</dc:date>
    <item>
      <title>AutoIt Script how to interact with Chrome (login, copy text from a webpage into a box)</title>
      <link>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419590#M87625</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;With AutoIt I can interact with Internet Explorer, but when it comes with Chrome, the only way I found was with:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Support of Python (using selenium (pip install selenium/ from selenium import webdriver) )&lt;/LI&gt;&lt;LI&gt;or using direct Send("XYZ") to enter username and Send("{TAB}") ; &lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems I can't contact Chrome Directly like Internet Explorer, to search input field (by its ID) or extract an element (extract the text from the &amp;lt;h1 class="post-title"&amp;gt; element)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example &lt;A alt="https://practicetestautomation.com/practice-test-login/" href="https://practicetestautomation.com/practice-test-login/" target="_blank"&gt;https://practicetestautomation.com/practice-test-login/&lt;/A&gt; with AutoIT I can use Internet Explorer ( But for Chrome it seems impossibile to interact, unless I use python or a direct send)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to write the below script but with Chrome?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Create the COM object for Internet Explorer&lt;/P&gt;&lt;P&gt;Global $oIE = ObjCreate("InternetExplorer.Application")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Navigate to the URL&lt;/P&gt;&lt;P&gt;$oIE.Navigate("&lt;A alt="https://practicetestautomation.com/practice-test-login/" href="https://practicetestautomation.com/practice-test-login/" target="_blank"&gt;https://practicetestautomation.com/practice-test-login/&lt;/A&gt;")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Find the username input field (by its ID)&lt;/P&gt;&lt;P&gt;Local $oUsernameField = $oIE.document.getElementById("username")&lt;/P&gt;&lt;P&gt;If IsObj($oUsernameField) Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;$oUsernameField.value = "student" ; Enter your username here&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Username field not found!")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Exit&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Find the password input field (by its ID)&lt;/P&gt;&lt;P&gt;Local $oPasswordField = $oIE.document.getElementById("password")&lt;/P&gt;&lt;P&gt;If IsObj($oPasswordField) Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;$oPasswordField.value = "Password123" ; Enter your password here&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Password field not found!")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Exit&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Find and click the Submit button (by its ID)&lt;/P&gt;&lt;P&gt;Local $oSubmitButton = $oIE.document.getElementById("submit")&lt;/P&gt;&lt;P&gt;If IsObj($oSubmitButton) Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;$oSubmitButton.Click() ; Click the submit button&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Submit button not found!")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Exit&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;; Now, extract the text from the &amp;lt;h1 class="post-title"&amp;gt; element&lt;/P&gt;&lt;P&gt;Local $oTitleElement = $oIE.document.getElementsByClassName("post-title")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If IsObj($oTitleElement) And $oTitleElement.length &amp;gt; 0 Then&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;; Extract the text from the &amp;lt;h1 class="post-title"&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;Local $sMessage = $oTitleElement.item(0).innerText&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;; Copy the extracted text to the clipboard&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;ClipPut($sMessage)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;; , display the copied text in a message box&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Success Message", "The message copied to clipboard is: " &amp;amp; @CRLF &amp;amp; $sMessage)&lt;/P&gt;&lt;P&gt;Else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;MsgBox(0, "Error", "Could not find the success message!")&lt;/P&gt;&lt;P&gt;EndIf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much&lt;/P&gt;</description>
      <pubDate>Tue, 09 Dec 2025 22:49:43 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419590#M87625</guid>
      <dc:creator>A.ElSheredi582594</dc:creator>
      <dc:date>2025-12-09T22:49:43Z</dc:date>
    </item>
    <item>
      <title>Re: AutoIt Script how to interact with Chrome (login, copy text from a webpage into a box)</title>
      <link>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419591#M87626</link>
      <description>&lt;P&gt;Hi @ABDOU LAZEZ HUSSIEN EL SHEREDI​&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The AutoIt team has created a WebDriver UDF that supports Chrome, Firefox, Edge, etc.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;https://www.autoitscript.com/forum/topic/191990-webdriver-udf&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;https://www.autoitscript.com/forum/topic/212240-webdriver-for-chrome/&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;With this UDF you can write almost the same style code as Selenium. It gives you Chrome automation without switching programming language.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope it helps!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 10 Dec 2025 00:53:22 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419591#M87626</guid>
      <dc:creator>M.Vora780263</dc:creator>
      <dc:date>2025-12-10T00:53:22Z</dc:date>
    </item>
    <item>
      <title>Re: AutoIt Script how to interact with Chrome (login, copy text from a webpage into a box)</title>
      <link>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419592#M87627</link>
      <description>&lt;P&gt;@Malhar Vora​&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you appreciated! I will try it&lt;/P&gt;</description>
      <pubDate>Sun, 14 Dec 2025 02:44:46 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/pam-self-hosted-discussions/autoit-script-how-to-interact-with-chrome-login-copy-text-from-a/m-p/1419592#M87627</guid>
      <dc:creator>A.ElSheredi582594</dc:creator>
      <dc:date>2025-12-14T02:44:46Z</dc:date>
    </item>
  </channel>
</rss>

