Recently Browsing 0 members
No registered users viewing this page.
Help opening IE maximized, opening url, identifying how to determine which "on-click" button to click onBy Mariog2000
I've tried for a few days to simply open a url in IE and click an IE object that I can't "TAB" to and don't want to use a mouse-click if at all possible. I've read up on things like using IEAction and IETagNameGetCollection to find the object but not smart enough to figure out how that works with my url or how to tell if my url is "basic" or a "form", "frameset", "iframe", etc.
The other problem is I've tried using the "Run" and "ShellExecute" commands to open the browser, which works, but it opens it in a way that doesn't include my currently logged in user account. For example, if I just click IE or Chrome for that matter and open my default homepage of google, the page that opens knows I'm logged in. When I use "Send" "ShellExecute" or "_IE_Create" they always open pages generically which would require a login.
So questions are, if I have a URL I'm trying to open, that's passes the currently logged on users credentials when opening the page (no clue where that happens)
1. Are there any code examples someone is willing to share that opens my IE maximized, with logged in credentials, and
2. Once that works, can someone suggest a technique a non-developer can find which IE Objects I need to send a "click" to so it opens the correct menu, pop-up, url, etc., associated with that object. I've copied what doesn't work and sure I'm way off but it's not for a lack of effort. I'll keep trying and post updates but not looking good 🙂
Func selection ()
Global $oIE = _IECreate ("https://internal-webpage.aspx")
Local $selectid = _IEGetObjByName ($oIE, "signageNo")
Local $button = _IEGetObjByName ($oIE, "GO")
_IEFormElementOptionSelect ($selectid, "3")
#include <IE.au3> Call ("selection") Func selection () Global $oIE = _IECreate ("https://internal-webpage.aspx") Local $selectid = _IEGetObjByName ($oIE, "signageNo") Local $button = _IEGetObjByName ($oIE, "GO") _IEFormElementOptionSelect ($selectid, "3") _IEAction ($button,"click") EndFunc 1.
I want to set the value of a input, but I only have the input name and input id. I cannot find a form in the source. Form collection does not return any results.
Is there a way to use FormElementSetValue without a form name? Can I use _IEGetObjByName or _IEGetObjById? If so, how do I set the value once I have the object? Where do I go from here? Local $oIE = _IEAttach("[Website Goes Here"]) Local $oForm = _IEFormGetCollection($oIE, 1) Local $oQuery = _IEFormElementGetCollection($oForm, 4) _IEFormElementSetValue($oQuery, "Set it to this")
below function returns an "object collection" (not sure if that's the correct term) of 'a' elements grabbed from within //*[@id="J_DetailMeta"].
However, I need the returned collection not to include objects with 'aria-disabled = true'. Is there a way of removing specific objects from such a collection?
Func GetObjectList($sPicker) $oDetailMeta = _IEGetObjById($oIE, "J_DetailMeta") If Not @error Then $tags = $oDetailMeta.GetElementsByTagName("ul") For $tag in $tags $data_ID_value = $tag.GetAttribute("data-property") If $sPicker = "color" Then If $data_ID_value = '????' Or $data_ID_value = "????" Then $oReturnList = $tag.GetElementsByTagName("a") EndIf ElseIf $sPicker = "network" Then If $data_ID_value = '????' Then $oReturnList = $tag.GetElementsByTagName("a") EndIf ElseIf $sPicker = "storage" Then If $data_ID_value = '????' Then $oReturnList = $tag.GetElementsByTagName("a") EndIf EndIf Next EndIf Return $oReturnList EndFunc $oColorList = GetObjectList("color") For $oColor In $oColorList If StringInStr($oColor.GetAttribute("aria-disabled"), "true") <= 0 Then ; remove object from the collection ??? EndIf Next
>"C:\Program Files (x86)\AutoIt3\SciTE\..\AutoIt3.exe" "C:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.au3" /ShowGui /prod /in "C:\AutoIt\pegasus\wings.au3" +>08:02:43 Starting AutoIt3Wrapper v.19.102.1901.0 SciTE v.188.8.131.52 Keyboard:00000409 OS:WIN_10/ CPU:X64 OS:X64 Environment(Language:0409) CodePage:0 utf8.auto.check:4 +> SciTEDir => C:\Program Files (x86)\AutoIt3\SciTE UserDir => C:\Users\x\AppData\Local\AutoIt v3\SciTE\AutoIt3Wrapper SCITE_USERHOME => C:\Users\x\AppData\Local\AutoIt v3\SciTE -> No changes made.. >Running Au3Stripper (19.102.1901.0) from:C:\Program Files (x86)\AutoIt3\SciTE\Au3Stripper cmdline: -### StripOnly/StripFunc Error: Found ObjEvent() statement using unsolvable Func, which will/could lead to removal of Funcs that are used by this Function. >### current Func: _1p2 c:\program files (x86)\autoit3\include\ie.au3(2572,1): Warning for line:$__g_oIEErrorHandler = ObjEvent("AutoIt.Error", $__g_sIEUserErrorHandler) -### StripOnly/StripFunc Error: Found Call() statement using unsolvable Func, which will/could lead to removal of Funcs that are used by this Function. >### current Func: _1te c:\program files (x86)\autoit3\include\sqlite.au3(609,1): Warning for line:$iCbRval = Call($sCallBack, $aDataRow) -### StripOnly/StripFunc Error: Found Call() statement using unsolvable Func, which will/could lead to removal of Funcs that are used by this Function. >### current Func: _1te c:\program files (x86)\autoit3\include\sqlite.au3(625,1): Warning for line:$iCbRval = Call($sCallBack, $aDataRow) My issue is specifically with the Call($sCallBack, xyz) part. I declared a Global with that name and thought I had it sorted. Previous releases appear content with that solution... Current I get this.
Question are these:
Should there be a default $sCallBack define in the provided include? What exactly should the "user defined" Callback function look like? And where is it defined? Sorry I am lost.
1/02/2018: Uploaded a new SciTe4AutoIt3.exe v19.102.1901.0 installer.
This version contains the bugfix release for SciTE 4.1.2.
There has been a major update for Tidy allowing now inline comments without them being shifted to the left by default.
See this thread for the total story about the new behavior and the added options
==> SciTE4AutoIt3 v19.102.1901.0
Addition/Changes/Fixes in the current installer:
-------------------------------------------------------------------------------------------------- 2-1-2019 *** Merged the SciTE v 4.1.2 by Neil Hodgson with our own version of SciTE. (Jos) - Fixed regex issue for Alt+F in AutoItTools.lua - Fixed another regex issue for several functions in AutoItTools.lua - Fixed Header parameters now showing None when none are - Fixed jump to function to also jump to the right Column again. - Restored AutoItTools:Copy_BookMarks() functionality *** Updated AutoIt3Wrapper v19.102.1901.0 (Jos) - 18.703.1808.1 renamed "#AutoIt3Wrapper_Au3Stripper_Stop_OnError" to "#AutoIt3Wrapper_Au3Stripper_OnError" with now as options S,C,F,Stop,Continue,ForceUse - 18.708.1148.1 Added #include <WinAPIFiles.au3> back in the included file list to ensure backward compatibility. - 18.708.1148.2 Added "Tidy_Stop_OnError" support to the AutoIt3Wrapper.INI file. Changed HiDPI settings for Win 10 compatibility. - 18.708.1148.4 Added logic to be able to display Console Output of script that have #RequireAdmin while SciTE runs at normal level. - 18.708.1148.5 Added support to allow to Stop Execution or Restart for scripts with #RequireAdmin while SciTE runs at normal level. It won't hang anymore when you reply No on the UAC and detect the elevated process didn;t start. - 18.708.1148.6 Reverted HiDPI changes made in 18.708.1148.2 as problems are reported. needs investigation. - 18.708.1148.7 Changed check for RequireAdmin AutoIt3Wrapper startup. - 18.708.1148.8 Added #include <APIResConstants.au3> for backwards compatibility with AutoIt3 v3.3.14.x. *** Updated Au3Stripper v19.102.1901.0 (Jos) - 18.708.1148.1 Fixed issue finding variable names on multiline statements - 18.708.1148.2 Added check for ending \ in the AutoIt3Dir, and remove it when there, to avoid duplication of includes. - recompiled with PellesC 6 to make it compatible with WinXP again. *** Updated SciTEConfig v19.102.1901.0 (Jos) - 18.708.1148.1 Update to allow comments in *.SciTEConfig file lines. (JPM) This update includes the updated shemes to allow changing between them. *** Updated Tidy v19.102.1901.0 (Jos) - 18.708.1148.1: Fix bug handling Directivelines ending with continuation character - 18.708.1148.2: Fixed indentation when a "None breaking space"(C2A0) character is used in a UTF file. - 18.708.1148.3: Fix bug when a continuation line starts with +x, where is would add a space between +- and number. - 18.708.9999.x: Rewrite of some internal code to allow inlinecomments to remain at their current position. Details can be found in this post: https://www.autoitscript.com/forum/topic/196221-tidy-major-update-27-10-requesting-help-with-testing/ - 18.708.9999.22: Released to Beta. - 18.708.9999.23: Added option to totally skip commentblocks so now the options are: #Tidy_Parameters=/tcb=0 =>only indent the whole commentblock (default) /tcb or /tcb=1 =>Tidy inside commentblock /tcb=-1 =>leave whole commentbock alone Tidy.INI:#--> Tidy commentblock 0=only indent the whole commentblock (default=0) # 1=Tidy inside commentblock # -1=leave whole commentbock alone Tidy_commentblock=0 - 18.708.9999.24: Added check for ending \ in the AutoIt3Dir and remove it when there. - recompiled with PellesC 6 to make it compatible with WinXP again. --------------------------------------------------------------------------------------------------
==> ScitillaHistory page containing all SciTE-Scintilla updates.
==> Visit the SciTE4AutoIt3 Download page for the latest versions
==> Check the online documentation for an overview of all extra's you get with this installer.