Jump to content

Recommended Posts

I am having trouble finding a good way to click these "button" below. 

image.png.79cfccdc339818423974807f892b9f8a.png

I only need to be able to click them when they have both yes/no. Otherwise I don't have to worry about them. For instance if they looked like this I would NOT have worry about clicking them and can just ignore them all togheter.(Below Picture)

image.png.2a82fa8d6bd12395db1991f0b443df49.png

The problem is as mentioned in the title, all of the ID's  are dynamic. (Classes too)

image.thumb.png.b6408eef8fcc0faa00459d55495a5ba9.png

Here is what it looks like if yes is already selected.

image.thumb.png.7ee78a1716ac60bba62d4d4a18eda7a2.png

This is what I was using to select the the button. However, I need to know if the button has already been clicked/selected or not.

_WD_LoadWait($sSession)
    $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//span[text() = 'Offered access to electronic health information?']")         
    Sleep(1000)
    _WD_ElementAction($sSession, $sElement, 'click')
    Sleep(500)
    _WD_Action($sSession, "actions", $sActionTab)
    Sleep(500)
    _WD_Action($sSession, "actions", $sActionEnter)

Is there a way I can get the count of spans in the span class-"s_636" by tabbing over to the button? I am hoping someone might have some ideas on what I can try.

Unfortunally, The site is for work so giving the site wont do any good. 

Life's simple. You make choices and you don't look back.

Link to post
Share on other sites

You can check if both span text exist. 

//div/div/span[span[contains(text(), "Yes")] and span[contains(text(), "No")]]

 

Saludos

Link to post
Share on other sites

Really appricate the help. 

That worked! Kinda. 

Is there a way I can ditinguish between the "Offered Access to Electronic Health" and "ACO leterr accepted" usign this method? I would like to avoid using the full xpath. Kind of my last resort really. 

Full X'path's

;Offerd Full Box
/html/body/div[2]/div[7]/div[2]/div[8]/div[1]/div/div/div[2]/div[2]/div[1]/div[2]/div/div/div[2]/div/div/div/div/div/div[2]/div/div/div/div[4]/div/div/div/div/div/div/div/div[2]/div/div/div/div[1]/div/div/div/div/table/tbody/tr/td[3]/div/div/span

;Offered Yes
/html/body/div[2]/div[7]/div[2]/div[8]/div[1]/div/div/div[2]/div[2]/div[1]/div[2]/div/div/div[2]/div/div/div/div/div/div[2]/div/div/div/div[4]/div/div/div/div/div/div/div/div[2]/div/div/div/div[1]/div/div/div/div/table/tbody/tr/td[3]/div/div/span/span[1]

;Offered No
/html/body/div[2]/div[7]/div[2]/div[8]/div[1]/div/div/div[2]/div[2]/div[1]/div[2]/div/div/div[2]/div/div/div/div/div/div[2]/div/div/div/div[4]/div/div/div/div/div/div/div/div[2]/div/div/div/div[1]/div/div/div/div/table/tbody/tr/td[3]/div/div/span/span[2]

;ACO Full Box
/html/body/div[2]/div[7]/div[2]/div[8]/div[1]/div/div/div[2]/div[2]/div[1]/div[2]/div/div/div[2]/div/div/div/div/div/div[2]/div/div/div/div[4]/div/div/div/div/div/div/div/div[2]/div/div/div/div[2]/div/div/div/div/table/tbody/tr/td[3]/div/div/span

;ACO Yes
/html/body/div[2]/div[7]/div[2]/div[8]/div[1]/div/div/div[2]/div[2]/div[1]/div[2]/div/div/div[2]/div/div/div/div/div/div[2]/div/div/div/div[4]/div/div/div/div/div/div/div/div[2]/div/div/div/div[2]/div/div/div/div/table/tbody/tr/td[3]/div/div/span/span[1]

;ACO No
/html/body/div[2]/div[7]/div[2]/div[8]/div[1]/div/div/div[2]/div[2]/div[1]/div[2]/div/div/div[2]/div/div/div/div/div/div[2]/div/div/div/div[4]/div/div/div/div/div/div/div/div[2]/div/div/div/div[2]/div/div/div/div/table/tbody/tr/td[3]/div/div/span/span[2]

 

Life's simple. You make choices and you don't look back.

Link to post
Share on other sites

Did you try _WD_GetElementByRegEx()

.?

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 for other useful stuff click the following button:

Spoiler

Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind. 

My contribution (my own projects): * Debenu Quick PDF Library - UDF * Debenu PDF Viewer SDK - UDF * Acrobat Reader - ActiveX Viewer * UDF for PDFCreator v1.x.x * XZip - UDF * AppCompatFlags UDF * CrowdinAPI UDF * _WinMergeCompare2Files() * _JavaExceptionAdd() * _IsBeta() * Writing DPI Awareness App - workaround * _AutoIt_RequiredVersion() * Chilkatsoft.au3 UDF * TeamViewer.au3 UDF * JavaManagement UDF * VIES over SOAP * WinSCP UDF * GHAPI UDF - modest begining - comunication with GitHub REST APIErrorLog.au3 UDF - A logging Library * Include Dependency Tree (Tool for analyzing script relations) *

My contribution to others projects or UDF based on  others projects: * _sql.au3 UDF  * POP3.au3 UDF *  RTF Printer - UDF * XML.au3 UDF * ADO.au3 UDF SMTP Mailer UDF * Dual Monitor resolution detection * * 2GUI on Dual Monitor System * _SciLexer.au3 UDF * SciTE - Lexer for console pane

Useful links: * Forum Rules * Forum etiquette *  Forum Information and FAQs * How to post code on the forum * AutoIt Online Documentation * AutoIt Online Beta Documentation * SciTE4AutoIt3 getting started * Convert text blocks to AutoIt code * Games made in Autoit * Programming related sites * Polish AutoIt Tutorial * DllCall Code Generator * 

Wiki: Expand your knowledge - AutoIt Wiki * Collection of User Defined Functions * How to use HelpFile * Good coding practices in AutoIt * 

OpenOffice/LibreOffice/XLS Related: WriterDemo.au3 * XLS/MDB from scratch with ADOX

IE Related:  * How to use IE.au3  UDF with  AutoIt v3.3.14.x * Why isn't Autoit able to click a Javascript Dialog? * Clicking javascript button with no ID * IE document >> save as MHT file * IETab Switcher (by LarsJ ) * HTML Entities * _IEquerySelectorAll() (by uncommon) * IE in TaskSchedulerIE Embedded Control Versioning (use IE9+ and HTML5 in a GUI) * PDF Related:How to get reference to PDF object embeded in IE * IE on Windows 11

I encourage you to read: * Global Vars * Best Coding Practices * Please explain code used in Help file for several File functions * OOP-like approach in AutoIt * UDF-Spec Questions *  EXAMPLE: How To Catch ConsoleWrite() output to a file or to CMD *

I also encourage you to check awesome @trancexx code:  * Create COM objects from modules without any demand on user to register anything. * Another COM object registering stuffOnHungApp handlerAvoid "AutoIt Error" message box in unknown errors  * HTML editor

winhttp.au3 related : * https://www.autoitscript.com/forum/topic/206771-winhttpau3-download-problem-youre-speaking-plain-http-to-an-ssl-enabled-server-port/

"Homo sum; humani nil a me alienum puto" - Publius Terentius Afer
"Program are meant to be read by humans and only incidentally for computers and execute" - Donald Knuth, "The Art of Computer Programming"
:naughty:  :ranting:, be  :) and       \\//_.

Anticipating Errors :  "Any program that accepts data from a user must include code to validate that data before sending it to the data store. You cannot rely on the data store, ...., or even your programming language to notify you of problems. You must check every byte entered by your users, making sure that data is the correct type for its field and that required fields are not empty."

Signature last update: 2022-03-07

Link to post
Share on other sites

@mLipok I have been spending the better part of the day trying to grasp how regex works. I have gotten to the point where I can find "yes" and "no" and "offered access" ,etc. Using regex101.com with ECMAscript and https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions.  However, I am still not sure how I can find/specify only the yes and no below offered access or ACO Letter accepted and again only when both exist do I need to click it. 

image.thumb.png.b484bb335d66bf0b7fc0179621ecb3b0.png

image.png.024e702ca44bafff95b1ec6b389f4529.png

 

<div id="xiy_g-4" class="pn-i pn-i-flop" style="width: 100%;"><div id="xiy_1o" class="comp comp-g navcomp horiz pn pn-c pn-s" style="width: 100%;"><div id="xiy_1o-0" class="pn-i " style="padding-left: 2.2ex; width: 100%;"><div id="xiy_1p" class="comp comp-g navcomp pn pn-c pn-s vert" style="width: 100%;"><div id="xiy_1p-0" class="pn-i  s_85" style="width: 100%;"><div id="xiy_1q" class="pn-c navcomp s_39" data-navcomp-type="accordioncontrol"><div id="xiy_1q-sc" class="pn-w s_86" style="width: 100%;"><div id="xiy_1q-pn" class="pn pn-flop ec-bdy vert pinned-scroll s_87"><div class="pinned-spacer pn-i pn-i-flop link" data-pinned-spacer-for="yiy_2g" style="height: 36px;"></div><div id="yiy_1r" class="pn-i pn-i-flop ec-det persistent-data" role="region" aria-labelledby="xiy_2h-2-btn"><div id="xiy_1s" class="comp navcomp sc-n pn-c"><div id="xiy_1s-pn" class="comp-g pn pn-s horiz" style="width: 100%;"><div id="xiy_1t" class="comp comp-g navcomp pn pn-c pn-t vert persistent-data" style="width: 100%; table-layout:fixed;"><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_1u" class="comp rttable navcomp s_50 s_72 s_88 s_89 s_90 s_91 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_1u-t" class="s_100 recordtable" data-last-label-spanned-widths="47.00%" data-last-label-initial-width="47.00%" data-column-count="4" data-render-type="TM" data-registered-events=""><div id="xiy_1u-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_1u-bd" class="rtbody">  <colgroup><col class="col0"><col class="col1"><col class="col2"><col class="col3"></colgroup>  <tbody><tr id="yiy_1v" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_1w" class=" rtcell column0 rtdispblank"><div class="s_63">  <span class="s_92 rectbl-text">  &nbsp;  </span></div></td><td id="yiy_1x" class="s_98 rtcell column1"><div class="s_63"><div id="xiy_1y" class="flowcomp comp navcomp s_15"><span class="s_15"><span class="s_392">* </span><span class="s_94">Offered access to electronic health information?</span><span class="s_95"></span></span></div></div></td><td id="yiy_1z" class="s_98 rtcell column2 link" data-evt="C"><div class="s_99"><div id="xiy_20" class="flowcomp comp navcomp s_15"><span class="s_96"><span id="xiy_20-mL" data-evt="C" class="link navitem s_393" tabindex="0">Yes</span><span id="xiy_20-mM" data-evt="C" class="link navitem s_394" tabindex="0">No</span></span></div></div></td><td id="yiy_21" class=" rtcell column3 link" data-evt="C"><div class="s_63"><div id="xiy_22" class="comp rectbl-text-comp navcomp"><span id="xiy_22-s" class="s_8 rectbl-text">&nbsp;</span></div></div></td></tr>  </tbody></table></div></div></div></div></div><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_CM" class="comp rttable navcomp s_50 s_72 s_88 s_89 s_90 s_91 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_CM-t" class="s_100 recordtable" data-last-label-spanned-widths="47.00%" data-last-label-initial-width="47.00%" data-column-count="4" data-render-type="TM" data-registered-events=""><div id="xiy_CM-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_CM-bd" class="rtbody">  <colgroup><col class="col0"><col class="col1"><col class="col2"><col class="col3"></colgroup>  <tbody><tr id="yiy_CN" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_CO" class=" rtcell column0 rtdispblank"><div class="s_63">  <span class="s_92 rectbl-text">  &nbsp;  </span></div></td><td id="yiy_CP" class="s_98 rtcell column1"><div class="s_63"><div id="xiy_CQ" class="flowcomp comp navcomp s_15"><span class="s_15"><span class="s_392">* </span><span class="s_94">ACO Letter Accepted?</span><span class="s_95"></span></span></div></div></td><td id="yiy_CR" class="s_98 rtcell column2 link rtfocus" data-evt="C"><div class="s_99"><div id="xiy_CS" class="flowcomp comp navcomp s_15"><span class="s_96"><span id="xiy_CS-mR" data-evt="C" class="link navitem s_393" tabindex="0">Yes</span><span id="xiy_CS-mS" data-evt="C" class="link navitem s_394" tabindex="0">No</span></span></div></div></td><td id="yiy_CT" class=" rtcell column3 link" data-evt="C"><div class="s_63"><div id="xiy_CU" class="comp rectbl-text-comp navcomp"><span id="xiy_CU-s" class="s_8 rectbl-text">&nbsp;</span></div></div></td></tr>  </tbody></table></div></div></div></div></div><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_CX" class="comp rttable navcomp s_112 s_113 s_114 s_50 s_72 s_88 s_89 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_CX-t" class="s_100 recordtable" data-last-label-spanned-widths="45.00%" data-last-label-initial-width="45.00%" data-column-count="5" data-render-type="TM" data-registered-events=""><div id="xiy_CX-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_CX-bd" class="rtbody">  <colgroup><col class="col0"><col class="col1"><col class="col2"><col class="col3"><col class="col4"></colgroup>  <tbody><tr id="yiy_CY" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_CZ" class=" rtcell column0 rtdispblank"><div class="s_63">  <span class="s_92 rectbl-text">  &nbsp;  </span></div></td><td id="yiy_Ca" class="s_98 rtcell column1"><div class="s_63"><div id="xiy_Cb" class="flowcomp comp navcomp s_15"><span class="s_15"><span class="s_93">* </span><span class="s_94">Date:</span><span class="s_95"></span></span></div></div></td><td id="yiy_Cc" class="s_98 rtcell column2 link" data-evt="C"><div class="s_63"><div id="xiy_Cd" data-evt="C" data-evh="Pweb.event.incrementClickCount" class="comp navcomp s_115"><input id="xiy_Cd-i" type="text" spellcheck="false" autocomplete="off" maxlength="" style="box-sizing:border-box;width:100%;vertical-align:top;" name="iniy_79" value="09/15/22" class="navitem s_116" data-fieldchanged-url="./00000000000226tcca.mthd"></div></div></td><td id="yiy_Ce" class="s_102 rtcell column3 link" data-evt="C"><div class="s_63"><div id="xiy_Cf" class="flowcomp comp navcomp s_31"><span class="s_31"><img id="xiy_Cf-mG" data-evt="C" class="navitem link" tabindex="0" src="Pub/Web/Icon/CalendarSmall.png" alt="Date" title="Date"></span></div></div></td><td id="yiy_Cg" class=" rtcell column4 link" data-evt="C"><div class="s_63"><div id="xiy_Ch" class="comp rectbl-text-comp navcomp"><span id="xiy_Ch-s" class="s_8 rectbl-text">&nbsp;</span></div></div></td></tr>  </tbody></table></div></div></div></div></div><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_25" class="comp rttable navcomp s_101 s_50 s_72 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_25-t" class="s_100 recordtable" data-last-label-spanned-widths="100.00%" data-last-label-initial-width="100%" data-column-count="1" data-render-type="TM"><div id="xiy_25-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_25-bd" class="rtbody">  <colgroup><col class="col0"></colgroup>  <tbody><tr id="yiy_26" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_27" class=" rtcell column0 rtdispblank"><div class="s_63">  <span class="s_8 rectbl-text">  &nbsp;  </span></div></td></tr>  </tbody></table></div></div></div></div></div><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_2A" class="comp rttable navcomp s_101 s_50 s_72 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_2A-t" class="s_100 recordtable" data-last-label-spanned-widths="100.00%" data-last-label-initial-width="100%" data-column-count="1" data-render-type="TM"><div id="xiy_2A-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_2A-bd" class="rtbody">  <colgroup><col class="col0"></colgroup>  <tbody><tr id="yiy_2B" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_2C" class="s_102 rtcell column0"><div class="s_63"><div id="xiy_2D" class="flowcomp comp navcomp s_31"><span class="s_31"><span>Financial Counsel</span></span></div></div></td></tr>  </tbody></table></div></div></div></div></div><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_2G" class="comp rttable navcomp s_103 s_50 s_72 s_88 s_89 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_2G-t" class="s_100 recordtable" data-last-label-spanned-widths="70.00%" data-last-label-initial-width="70.00%" data-column-count="3" data-render-type="TM" data-registered-events=""><div id="xiy_2G-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_2G-bd" class="rtbody">  <colgroup><col class="col0"><col class="col1"><col class="col2"></colgroup>  <tbody><tr id="yiy_2H" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_2I" class=" rtcell column0 rtdispblank"><div class="s_63">  <span class="s_92 rectbl-text">  &nbsp;  </span></div></td><td id="yiy_2J" class="s_98 rtcell column1"><div class="s_63"><div id="xiy_2K" class="flowcomp comp navcomp s_15"><span class="s_15"><span class="s_93"></span><span class="s_94">NSB Disclosure provided</span><span class="s_95"></span></span></div></div></td><td id="yiy_2L" class="s_98 rtcell column2 link" data-evt="C"><div class="s_111"><div id="xiy_2M" class="comp navcomp s_109"><div id="xiy_2M-h" class="s_110 navitem" tabindex="0"><span class="vcenterhelper"></span><span id="xiy_2M-s" class="vcenterelement idp-display">Yes</span><input id="xiy_2M-i" name="iniy_39" type="text" style="display:none;" value="Yes" readonly=""></div></div></div></td></tr>  </tbody></table></div></div></div></div></div><div class="pn-row"><div class="pn-i pn-cell" style="padding-left: 2%; width: 95%;"><div id="xiy_2P" class="comp rttable navcomp s_112 s_113 s_114 s_50 s_72 s_88 s_89 s_65 afterResize persistent-data" data-after-resize="Pweb.comp.recordTable.afterResize_" data-navcomp-type="recordtable" data-evt="Ch C Fi Fo De" data-evh="Pweb.comp.recordTable.event"><div id="xiy_2P-t" class="s_100 recordtable" data-last-label-spanned-widths="45.00%" data-last-label-initial-width="45.00%" data-column-count="5" data-render-type="TM" data-registered-events=""><div id="xiy_2P-sc" class="s_80 rtscrollbody" style="overflow-y: hidden;"><table id="xiy_2P-bd" class="rtbody">  <colgroup><col class="col0"><col class="col1"><col class="col2"><col class="col3"><col class="col4"></colgroup>  <tbody><tr id="yiy_2Q" class="rtrow navcomp selected" data-navcomp-type="recordtablerow"><td id="yiy_2R" class=" rtcell column0 rtdispblank"><div class="s_63">  <span class="s_92 rectbl-text">  &nbsp;  </span></div></td><td id="yiy_2S" class="s_98 rtcell column1"><div class="s_63"><div id="xiy_2T" class="flowcomp comp navcomp s_15"><span class="s_15"><span class="s_93"></span><span class="s_94">NSB Disclosure date</span><span class="s_95"></span></span></div></div></td><td id="yiy_2U" class="s_98 rtcell column2 link" data-evt="C"><div class="s_63"><div id="xiy_2V" data-evt="C" data-evh="Pweb.event.incrementClickCount" class="comp navcomp s_115"><input id="xiy_2V-i" type="text" spellcheck="false" autocomplete="off" maxlength="" style="box-sizing:border-box;width:100%;vertical-align:top;" name="iniy_40" value="04/13/22" class="navitem s_116" data-fieldchanged-url="./0000000000016bpyjd.mthd"></div></div></td><td id="yiy_2W" class="s_102 rtcell column3 link" data-evt="C"><div class="s_63"><div id="xiy_2X" class="flowcomp comp navcomp s_31"><span class="s_31"><img id="xiy_2X-m2" data-evt="C" class="navitem link" tabindex="0" src="Pub/Web/Icon/CalendarSmall.png" alt="Date" title="Date"></span></div></div></td><td id="yiy_2Y" class=" rtcell column4 link" data-evt="C"><div class="s_63"><div id="xiy_2Z" class="comp rectbl-text-comp navcomp"><span id="xiy_2Z-s" class="s_8 rectbl-text">&nbsp;</span></div></div></td></tr>  </tbody></table></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div>

 

Edited by SkysLastChance

Life's simple. You make choices and you don't look back.

Link to post
Share on other sites

No luck, The site only works on our network. 

I would try an extension, but our IT has all extensions blocked.

Is there a manual way to do this?

I am gussing I am going to have to use the full xpath at this point. Which is fine I guess, it just breaks everytime we get and upadate to the site. >.<

Life's simple. You make choices and you don't look back.

Link to post
Share on other sites

hello @SkysLastChance
Can you save it to single MHTLM file and share it to us ? Of course there will be a need to anonymize the restricted data but this is a way to show as how this page looks like.

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 for other useful stuff click the following button:

Spoiler

Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind. 

My contribution (my own projects): * Debenu Quick PDF Library - UDF * Debenu PDF Viewer SDK - UDF * Acrobat Reader - ActiveX Viewer * UDF for PDFCreator v1.x.x * XZip - UDF * AppCompatFlags UDF * CrowdinAPI UDF * _WinMergeCompare2Files() * _JavaExceptionAdd() * _IsBeta() * Writing DPI Awareness App - workaround * _AutoIt_RequiredVersion() * Chilkatsoft.au3 UDF * TeamViewer.au3 UDF * JavaManagement UDF * VIES over SOAP * WinSCP UDF * GHAPI UDF - modest begining - comunication with GitHub REST APIErrorLog.au3 UDF - A logging Library * Include Dependency Tree (Tool for analyzing script relations) *

My contribution to others projects or UDF based on  others projects: * _sql.au3 UDF  * POP3.au3 UDF *  RTF Printer - UDF * XML.au3 UDF * ADO.au3 UDF SMTP Mailer UDF * Dual Monitor resolution detection * * 2GUI on Dual Monitor System * _SciLexer.au3 UDF * SciTE - Lexer for console pane

Useful links: * Forum Rules * Forum etiquette *  Forum Information and FAQs * How to post code on the forum * AutoIt Online Documentation * AutoIt Online Beta Documentation * SciTE4AutoIt3 getting started * Convert text blocks to AutoIt code * Games made in Autoit * Programming related sites * Polish AutoIt Tutorial * DllCall Code Generator * 

Wiki: Expand your knowledge - AutoIt Wiki * Collection of User Defined Functions * How to use HelpFile * Good coding practices in AutoIt * 

OpenOffice/LibreOffice/XLS Related: WriterDemo.au3 * XLS/MDB from scratch with ADOX

IE Related:  * How to use IE.au3  UDF with  AutoIt v3.3.14.x * Why isn't Autoit able to click a Javascript Dialog? * Clicking javascript button with no ID * IE document >> save as MHT file * IETab Switcher (by LarsJ ) * HTML Entities * _IEquerySelectorAll() (by uncommon) * IE in TaskSchedulerIE Embedded Control Versioning (use IE9+ and HTML5 in a GUI) * PDF Related:How to get reference to PDF object embeded in IE * IE on Windows 11

I encourage you to read: * Global Vars * Best Coding Practices * Please explain code used in Help file for several File functions * OOP-like approach in AutoIt * UDF-Spec Questions *  EXAMPLE: How To Catch ConsoleWrite() output to a file or to CMD *

I also encourage you to check awesome @trancexx code:  * Create COM objects from modules without any demand on user to register anything. * Another COM object registering stuffOnHungApp handlerAvoid "AutoIt Error" message box in unknown errors  * HTML editor

winhttp.au3 related : * https://www.autoitscript.com/forum/topic/206771-winhttpau3-download-problem-youre-speaking-plain-http-to-an-ssl-enabled-server-port/

"Homo sum; humani nil a me alienum puto" - Publius Terentius Afer
"Program are meant to be read by humans and only incidentally for computers and execute" - Donald Knuth, "The Art of Computer Programming"
:naughty:  :ranting:, be  :) and       \\//_.

Anticipating Errors :  "Any program that accepts data from a user must include code to validate that data before sending it to the data store. You cannot rely on the data store, ...., or even your programming language to notify you of problems. You must check every byte entered by your users, making sure that data is the correct type for its field and that required fields are not empty."

Signature last update: 2022-03-07

Link to post
Share on other sites

I was able to figure this out with alot of help from my co-worker using java script. 

Local $Text = 'ACO Letter Accepted?'
Local $Java = _WD_ExecuteScript($sSession,'var questionRow = Array.prototype.slice.call(document.querySelectorAll("div.pn-row tr")).find(element => element.querySelectorAll("td.column1 span span")[1].innerHTML == "' & $vText &'");return questionRow.querySelectorAll("td.column2 span span").length == 1;',Default,Default,"[value]")
Msgbox(0,"",$Java)

Thanks @Danp2 and @mLipok for all the help in the last couple years.

The webdriver udf's and wiki have been paramount in automating chrome for me.  Can't thank you both enough. 

Edited by SkysLastChance

Life's simple. You make choices and you don't look back.

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By corvo
      Hello!

      I've been trying to launch chrome through WD,  but for some reason, the user profile is not working, it just opens up the chrome window with the "temp" user. I've also made sure that the user profile path is correct by using "chrome://version". 
      Here is what I've got so far:
      #include "wd_helper.au3" #include "wd_capabilities.au3" #include "wd_core.au3" SetupChrome() _WD_CapabilitiesStartup() Local $sCapabilities = _WD_CapabilitiesGet() $sSession = _WD_CreateSession($sCapabilities) _WD_Navigate($sSession, "https://www.google.com") Func SetupChrome() _WD_Option('Driver', 'chromedriver.exe') _WD_Option('Port', 9515) _WD_Option('DriverParams', '--verbose --log-path="' & @ScriptDir & '\chrome.log"') _WD_Option('DriverParams', '--marionette-port 2828') $sDesiredCapabilities = '{"capabilities": {"alwaysMatch": {"goog:chromeOptions": {"w3c": true, "args":["--user-data-dir=C:\\Users\\' & @UserName & '\\AppData\\Local\\Google\\Chrome\\User Data\\", "--profile-directory=Profile 2"]}}}}' $_WD_DEBUG = $_WD_DEBUG_None ; You could also use $_WD_DEBUG_Error EndFunc  
      Thanks in advance!
       
    • By ThomasBennett
      Good morning, everyone, 
      I have had very good luck with using _WD_ElementActionEx 'CLICKANDHOLD'. What would be the best practice with dragging and dropping web elements? I would prefer to not to have to use any dragging and dropping but I haven't figured out a way to change the order the elements are displayed programmatically. 
      I have a list of elements that are drag and drop. These elements in code are using <UL></UL> for the entire list and the actual web elements that are being manipulated are in <LI></LI> tags. These do not look like a bulleted list but that is the code that is being used. I've spoken with the web developer and there isn't any hot keys or keyboard commands that can be used to move these elements.
      I know where the new and original web element appears and can select them using the _WD_WaitElement and _WD_FindElement combo. I can find the number of items in the list by looking at the code; I haven't started pulling the values out just yet. I am trying to figure out if there is a place to change the listed order.
      Using the 'CLICKANDHOLD' feature as part of _WD_ElementActionEx does work and I know more or less where I need to drop it the new web element; the problem I am having is scrolling exactly to where I need the new web element dropped. It should be dropped beneath the original web element. 
      What's the best method to output the number of children associated with the <UL></UL>? I am guessing that _WD_ElementActionEx 'CHILDCOUNT' would be it; but I haven't figured out how to get the call to output in a msgbox or in the console. 
      #cs ---------------------------------------------------------------- Name ..........: Please Note!.au3 Description ...: To be used to add new lessons to existing playlists and to update the pre-existing lesson with the Please Note! PowerPoint SciTE 32-bit ..: Version 4.4.6 Author(s) .....: Thomas E. Bennett Date ..........: 20220929 Recommended Reading / Requirements https://www.autoitscript.com/forum/topic/191990-webdriver-udf-w3c-compliant-version-01162021/#comments https://www.autoitscript.com/wiki/WebDriver https://www.autoitscript.com/wiki/WebDriver#Installation https://www.autoitscript.com/wiki/Adding_UDFs_to_AutoIt_and_SciTE https://www.autoitscript.com/autoit3/docs/intro/running.htm#CommandLine wd_core.au3 wd_helper.au3 From wd_core.au3 Global Const $_WD_LOCATOR_ByCSSSelector = "css selector" Global Const $_WD_LOCATOR_ByXPath = "xpath" Global Const $_WD_LOCATOR_ByLinkText = "link text" Global Const $_WD_LOCATOR_ByPartialLinkText = "partial link text" Global Const $_WD_LOCATOR_ByTagName = "tag name" #ce ---------------------------------------------------------------- #include "wd_core.au3" #include "wd_helper.au3" #include <MsgBoxConstants.au3> #include <Excel.au3> #include <AutoItConstants.au3> Local $sDesiredCapabilities, $sSession, $sElement ; Create application object and open an example workbook Local $oExcel = _Excel_Open() If @error Then Exit MsgBox($MB_SYSTEMMODAL, "Excel UDF: _Excel_RangeRead Example", "Error creating the Excel application object." & @CRLF & "@error = " & @error & ", @extended = " & @extended) Local $oWorkbook = _Excel_BookOpen($oExcel, @ScriptDir & "\{PRIVACY}.xlsx") If @error Then MsgBox($MB_SYSTEMMODAL, "Excel UDF: _Excel_RangeRead Example", "Error opening workbook '" & @ScriptDir & "\{PRIVACY}.xlsx'." & @CRLF & "@error = " & @error & ", @extended = " & @extended) _Excel_Close($oExcel) Exit EndIf ; Read data from a single cell on the active sheet of the specified workbook ;Local $sResult = _Excel_RangeRead($oWorkbook, Default, "A1") ;If @error Then Exit MsgBox($MB_SYSTEMMODAL, "Excel UDF: _Excel_RangeRead Example 1", "Error reading from workbook." & @CRLF & "@error = " & @error & ", @extended = " & @extended) ;MsgBox($MB_SYSTEMMODAL, "Excel UDF: _Excel_RangeRead Example 1", "Data successfully read." & @CRLF & "Value of cell A1: " & $sResult) SetupChrome() _WD_Startup() $sSession = _WD_CreateSession($sDesiredCapabilities) Sleep (15000) Local $aResult = _Excel_RangeRead($oWorkbook, Default, "A16:E16") For $i = 0 To UBound($aResult, 1) - 1 ;ConsoleWrite("========= Start Row =========" & @CRLF) ;ConsoleWrite($aResult[$i][0] & @CRLF) ; Column A -- Course Playlist Number ;ConsoleWrite($aResult[$i][1] & @CRLF) ; Column B -- Course Playlist Title ;ConsoleWrite($aResult[$i][2] & @CRLF) ; Column C -- Original Lesson Title ;ConsoleWrite($aResult[$i][3] & @CRLF) ; Column D -- Updated Lesson Number ;ConsoleWrite($aResult[$i][4] & @CRLF) ; Column E -- Updated Lesson Title ;ConsoleWrite("========= End Row =========" & @CRLF & @CRLF) _WD_Navigate($sSession, "{PRIVACY}" & $aResult[$i][0]) _WD_LoadWait($sSession, 2000) ; Find the Available Lessons search box and enter the appropriate value _WD_WaitElement($sSession, $_WD_LOCATOR_ByXPath, "//input[@id='titleSearch']") $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//input[@id='titleSearch']") ; Click the Sign in button _WD_ElementAction($sSession, $sElement, 'value', $aResult[$i][3]) Send("{Enter}") ; Find the correct "Add" hyperlink _WD_WaitElement($sSession, $_WD_LOCATOR_ByXPath, "//span[text()='" & $aResult[$i][4] & "']/following-sibling::div") $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//span[text()='" & $aResult[$i][4] & "']/following-sibling::div") ; Click the "Add" hyperlink _WD_ElementAction($sSession, $sElement, 'click') ; Number of Child Elements _WD_WaitElement($sSession, $_WD_LOCATOR_ByXPath, "//ul[@id='selected-items']") $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//ul[@id='selected-items']") _WD_ElementActionEx($sSession, $sElement, 'CHILDCOUNT') Exit ; Click and Hold the appropriate element _WD_WaitElement($sSession, $_WD_LOCATOR_ByXPath, "//ul[@id='selected-items']//span[@class='item-description' and text()='" & $aResult[$i][4] & "']/parent::li") $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//ul[@id='selected-items']//span[@class='item-description' and text()='" & $aResult[$i][4] & "']/parent::li") _WD_ElementActionEx($sSession, $sElement, 'clickandhold', 0, 0, 0, 10000) ; Hover the appropriate element _WD_WaitElement($sSession, $_WD_LOCATOR_ByXPath, "//ul[@id='selected-items']//span[@class='item-description' and text()='" & $aResult[$i][4] & "']/following-sibling::a") $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//ul[@id='selected-items']//span[@class='item-description' and text()='" & $aResult[$i][4] & "']/following-sibling::a") _WD_ElementActionEx($sSession, $sElement, 'HOVER') Exit Next Exit _WD_DeleteSession($sSession) _WD_Shutdown() Exit Func SetupChrome() ; Google Chrome _WD_Option('Driver', "C:\Users\thomas.bennett\Desktop\AutoIt\include\chromedriver.exe") _WD_Option('Port', 9515) ;_WD_Option('DriverParams', '--verbose --log-path="' & @ScriptDir & '\chrome.log"') $sDesiredCapabilities = '{"capabilities": {"alwaysMatch": {"unhandledPromptBehavior": "ignore", ' & _ '"goog:chromeOptions": {"w3c": true, "excludeSwitches": ["enable-automation"], "useAutomationExtension": false, ' & _ '"prefs": {"credentials_enable_service": false},' & _ '"args": ["start-maximized"] }}}}' EndFunc Console Output
      >"C:\Program Files (x86)\AutoIt3\SciTE\..\AutoIt3.exe" "C:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.au3" /run /prod /ErrorStdOut /in "C:\Users\thomas.bennett\Desktop\AutoIt\Please Note!\Please Note!.au3" /UserParams +>09:22:40 Starting AutoIt3Wrapper (21.316.1639.1) from:SciTE.exe (4.4.6.0) Keyboard:00000409 OS:WIN_10/2009 CPU:X64 OS:X64 Environment(Language:0409) CodePage:0 utf8.auto.check:4 +> SciTEDir => C:\Program Files (x86)\AutoIt3\SciTE UserDir => C:\Users\thomas.bennett\AppData\Local\AutoIt v3\SciTE\AutoIt3Wrapper SCITE_USERHOME => C:\Users\thomas.bennett\AppData\Local\AutoIt v3\SciTE >Running AU3Check (3.3.14.5) from:C:\Program Files (x86)\AutoIt3 input:C:\Users\thomas.bennett\Desktop\AutoIt\Please Note!\Please Note!.au3 +>09:22:40 AU3Check ended.rc:0 >Running:(3.3.14.5):C:\Program Files (x86)\AutoIt3\autoit3.exe "C:\Users\thomas.bennett\Desktop\AutoIt\Please Note!\Please Note!.au3" +>Setting Hotkeys...--> Press Ctrl+Alt+Break to Restart or Ctrl+BREAK to Stop. _WD_Option ==> Success [0] : Parameters: Option=Driver Value=C:\Users\thomas.bennett\Desktop\AutoIt\include\chromedriver.exe _WD_Option ==> Success [0] : Parameters: Option=Port Value=9515 _WD_IsLatestRelease ==> Success [0] : True _WD_Startup: OS: WIN_10 WIN32_NT 22000 _WD_Startup: AutoIt: 3.3.14.5 _WD_Startup: Webdriver UDF: 0.10.1 (Up to date) _WD_Startup: WinHTTP: 1.6.4.2 _WD_Startup: Driver: C:\Users\thomas.bennett\Desktop\AutoIt\include\chromedriver.exe (32 Bit) _WD_Startup: Params: _WD_Startup: Port: 9515 _WD_Startup: Command: "C:\Users\thomas.bennett\Desktop\AutoIt\include\chromedriver.exe" _WD_Startup ==> Success [0] __WD_Post ==> Success [0] : HTTP status = 200 _WD_CreateSession ==> Success [0] : 2542b35e47b8f9b2558cd92ad1418811 __WD_Post ==> Success [0] : HTTP status = 200 _WD_Navigate ==> Success [0] : Parameters: URL={PRIVACY} _WD_LoadWait ==> Success [0] : Parameters: Delay=2000 Timeout=Default Element=Default _WD_WaitElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@id='Username'] Delay=Default Timeout=Default Options=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_FindElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@id='Username'] StartNodeID=Default Multiple=Default ShadowRoot=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_ElementAction ==> Success [0] : Parameters: Command=value Option=<masked> _WD_WaitElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@id='Password'] Delay=Default Timeout=Default Options=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_FindElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@id='Password'] StartNodeID=Default Multiple=Default ShadowRoot=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_ElementAction ==> Success [0] : Parameters: Command=value Option=<masked> _WD_WaitElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@value='Sign In'] Delay=Default Timeout=Default Options=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_FindElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@value='Sign In'] StartNodeID=Default Multiple=Default ShadowRoot=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_ElementAction ==> Success [0] : Parameters: Command=click Option=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_Navigate ==> Success [0] : Parameters: URL={PRIVACY} _WD_LoadWait ==> Success [0] : Parameters: Delay=2000 Timeout=Default Element=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_Navigate ==> Success [0] : Parameters: URL={PRIVACY} _WD_LoadWait ==> Success [0] : Parameters: Delay=2000 Timeout=Default Element=Default _WD_WaitElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@id='titleSearch'] Delay=Default Timeout=Default Options=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_FindElement ==> Success [0] : Parameters: Strategy=xpath Selector=//input[@id='titleSearch'] StartNodeID=Default Multiple=Default ShadowRoot=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_ElementAction ==> Success [0] : Parameters: Command=value Option=<masked> _WD_WaitElement ==> Timeout [7] : Parameters: Strategy=xpath Selector=//span[text()='{PRIVACY}']/following-sibling::div Delay=Default Timeout=Default Options=Default __WD_Post ==> No match [8] : HTTP status = 404 _WD_FindElement ==> No match [8] : Parameters: Strategy=xpath Selector=//span[text()='{PRIVACY}']/following-sibling::div StartNodeID=Default Multiple=Default ShadowRoot=Default __WD_Post ==> No match [8] : HTTP status = 404 _WD_ElementAction ==> No match [8] : Parameters: Command=click Option=Default _WD_WaitElement ==> Success [0] : Parameters: Strategy=xpath Selector=//ul[@id='selected-items'] Delay=Default Timeout=Default Options=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_FindElement ==> Success [0] : Parameters: Strategy=xpath Selector=//ul[@id='selected-items'] StartNodeID=Default Multiple=Default ShadowRoot=Default __WD_Post ==> Success [0] : HTTP status = 200 _WD_ExecuteScript ==> Success [0] _WD_ElementActionEx ==> Success [0] : Parameters: Element=21c01052-8b86-4058-b8f6-d9dfa750f9ee Command=CHILDCOUNT XOffset=Default YOffset=Default Button=Default HoldDelay=Default Modifier=Default +>09:23:20 AutoIt3.exe ended.rc:0 +>09:23:20 AutoIt3Wrapper Finished. >Exit code: 0 Time: 40.88  

      My thought is once AutoIt knows how many child elements there are; I am hoping that there would be a way to change the sort or priority order that the <LI></LI>'s are shown in. 
      Thank you for your time and efforts on this and as I progress I'll update this topic, 




      Thomas 
    • By ThomasBennett
      #cs ---------------------------------------------------------------- Name ..........: ignore.au3 Description ...: Testing _WD_HighlightElements SciTE 32-bit ..: Version 4.4.6 Author(s) .....: Thomas E. Bennett Date ..........: 20220929 Recommended Reading / Requirements https://www.autoitscript.com/forum/topic/191990-webdriver-udf-w3c-compliant-version-01162021/#comments https://www.autoitscript.com/wiki/WebDriver https://www.autoitscript.com/wiki/WebDriver#Installation https://www.autoitscript.com/wiki/Adding_UDFs_to_AutoIt_and_SciTE https://www.autoitscript.com/autoit3/docs/intro/running.htm#CommandLine wd_core.au3 wd_helper.au3 From wd_core.au3 Global Const $_WD_LOCATOR_ByCSSSelector = "css selector" Global Const $_WD_LOCATOR_ByXPath = "xpath" Global Const $_WD_LOCATOR_ByLinkText = "link text" Global Const $_WD_LOCATOR_ByPartialLinkText = "partial link text" Global Const $_WD_LOCATOR_ByTagName = "tag name" #ce ---------------------------------------------------------------- #include "wd_core.au3" #include "wd_helper.au3" #include "wd_cdp.au3" #include "wd_capabilities.au3" #include <MsgBoxConstants.au3> Local $sDesiredCapabilities, $sElement, $sSession Func SetupChrome() ; Google Chrome _WD_Option('Driver', @ScriptDir & "\include\chromedriver.exe") _WD_Option('Port', 9515) ;_WD_Option('DriverParams', '--verbose --log-path="' & @ScriptDir & '\chrome.log"') $sDesiredCapabilities = '{"capabilities": {"alwaysMatch": {"unhandledPromptBehavior": "ignore", ' & _ '"goog:chromeOptions": {"w3c": true, "excludeSwitches": ["enable-automation"], "useAutomationExtension": false, ' & _ '"prefs": {"credentials_enable_service": false},' & _ '"args": ["start-maximized"] }}}}' EndFunc SetupChrome() _WD_Startup() $sSession = _WD_CreateSession($sDesiredCapabilities) Sleep (15000) ; DuckDuckGo _WD_Navigate($sSession, "https://duckduckgo.com/") _WD_LoadWait($sSession, 2000) ; Find the Search field _WD_WaitElement($sSession, $_WD_LOCATOR_ByXPath, "//input[@id='search_form_input_homepage']") $sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXPath, "//input[@id='search_form_input_homepage']") ; Highlight the Search field _WD_HighlightElements($sSession, $sElement, 3) MsgBox(0,"","") Exit ;this is here on purpose _WD_DeleteSession($sSession) _WD_Shutdown() Exit Good evening, everyone, 
      I am trying to get any element to highlight using the _WD_HighlightElements function; I've tried different elements and for a time I thought maybe because I am working in Windows 11 so I switched back to Windows 10 same issue; I can't get the found element to highlight. What am I doing incorrectly?
      Console Output _WD_FindElement: {"value":{"element-6066-11e4-a52e-4f735466cecf":"0e212d4f-8437-42a0-a56a-bc8694fe6e66"}} _WD_WaitElement ==> Success __WD_Post: URL=HTTP://127.0.0.1:9515/session/0e05f8ea99dba06bb84908b0b46fe881/element; $sData={"using":"xpath","value":"//input[@id='search_form_input_homepage']"} __WD_Post: StatusCode=200; ResponseText={"value":{"element-6066-11e4-a52e-4f735466cecf":"0e212d4f-8437-42a0-a56a-bc8694fe6e66"}}... _WD_FindElement: {"value":{"element-6066-11e4-a52e-4f735466cecf":"0e212d4f-8437-42a0-a56a-bc8694fe6e66"}} Thank you for your time on this,




      Thomas E. Bennett
    • By ThomasBennett
      Good morning, everyone, 
      I am using WebDriver with ChromeDriver version 105.0.5195.52
      I have the script almost completed; this is going to be used as a wait / pause until the file has completed uploading. I was able to find where the value: "C:\\fakepath\\Vladimir Harkonnen.jpg" is stored. I am trying to figure out how to read this value. This is part of an <input type="file"> element. Reading / finding the value would be the trigger to allow the script to continue. I don't know very much but I feel like I am either not using WebDriver correctly or possibly it won't be able to help me with what I am trying to do.
      Please see the attached screenshot. 
      Thank you for your time, experience, and patience with me,




      Thomas Bennett
       

    • By TTE26
      For the past two days I've been reading all Wiki pages, installed all the demos etc. but I am still unable to do this simple workflow
      1. I want to use WebDriver UDF to open Chrome (Set chrome option arguments - Window Size, Pixel ratio, device type and platform name, user-agent.)
      2. On new Tab I want to read the tab Title and save it into a TXT file.
      3. I need to save the Session ID with my previosly set Capabilities into a file.
      4. I want to close the chrome window.
      Then
      5. I want to open Chrome again, but with my previosly saved Session ID and Capabilities list from the file.
      6. And minimaze the window state.
      7. After 30 seconds, close the chrome.
      I would really appreciate for the WebDriver UDF Helper file, to have also basic code examples, for non coders. For example how to open a windwow etc., save sessions, etc.
      Anyway, if someone could help me get started and help me with this workflow, that would be much appreaciated. 😔
×
×
  • Create New...