zasxes
Active Members-
Posts
51 -
Joined
-
Last visited
zasxes's Achievements
Wayfarer (2/7)
0
Reputation
-
How do I get the while look to continue to loop and not wait for the Test func to complete. Can the Test() func be called while it is already running? $Test = 0 While 1 $Test = $Test+1 Sleep (3000) Test($Test) WEnd Exit Func Test($1) IniWrite("C:\Temp\mytest.ini", "section2", @HOUR & ":" & @MIN & ":" & @SEC, "Event Start = " & $1) Sleep (5000) IniWrite("C:\Temp\mytest.ini", "section2", @HOUR & ":" & @MIN & ":" & @SEC, "Event End = " & $1) EndFunc
-
Thanks for the quick replies. I will let you know how well this works. One quick question. I am a bit new to Reg Expressions. If this correct: "(?s)(?i)Save|Submit|\_SibB|_SIG,AddLine" The above basicly means "(?s=Find any match)(?i=Not Case Sensituive)Save |=Or Submit Or (\=Special Char) _SibB Or _SIG (What does the comma do?) Addline" I guess the onlything I am unsure of is the comma before Addline
-
This function basically waits until the FooterPage loads on a website then checks if certain objects exist. If they do it then disables them one way or another. The reason I do not simply have the .id spelled out is because in some cases it is dynamicly generated. The problem with the function is that it can be slow at times and you can beat it to the objects and use them before I disable them. If possible I would like to speed this process up or find a way to ensure the objects cannot be used until after this function sets them to "SafeMode = 1". Anyt thoughts would be helpful. Func IEEvent_FrameNavigateComplete($1) If StringInStr($1, "FooterPage") then ToolTip("In Frame", 0, 0) With $B_oIE5 $elems = .document.frames.main.document.getElementsByTagName("*") $Max = $elems.length $count = 0 For $elem in $elems $count = $count + 1 if isobj($elem) then if $elem.SafeMode.value <> 1 then $elem.setAttribute("SafeMode",1) if StringRight($elem.id, 3) = "_SB" then $elem.disabled="True" ; Submit Button (Subjects) if StringRight($elem.id, 6) = "log_IB" then $elem.disabled="True" ;Inactivate Log Line button if StringInStr($elem.id, "Save") then $elem.disabled="True" ; Submit Button if StringInStr($elem.id, "SubmitBut") then $elem.disabled="True" ; Submit Button if StringInStr($elem.id, "AddLine") then $elem.disabled="True" ; Add log line if StringInStr($elem.id, "AddLine") then $elem.href=$1 ; Add log line if StringInStr($elem.id, "_SibB") then $elem.disabled="True" ; Sign Box if StringInStr($elem.id, "_SIG") then $elem.disabled="True" ; Sign Button Endif EndIf Next ;WEnd EndWith EndIf EndFunc
-
I am trying to read the IE Dom and put the string 333369NPP2001 (UAT) from the HTML below into a variable. I thought I could use .target but that just shows main. how do I access that data? <A id=ListDisplayNavigation_dgObjects__ctl3_hpObject href="HomePage.aspx?LD_StudyID=263&mdsc=6%3a467331" target=main>333369NPP2001 (UAT)</A>
-
I use IE Web Developer to easily see the path for elements in web pages. For example i can click a login button in Auto it by using document.forms.LoginForm.UserPasswordBox.click instead of the IE UDF in some cases this is easier. Are there any other tools that provide the path to objects like this? The reason I ask is it seems there various ways to get to an object.
-
I am creating a embedded IE window that people will use as a safe portal into a web application and the applet will also track what is being done. The tracking works fine and that is the main part of the script. I am trying to use AdlibEnable to check if the buttons exist and if they do to disable them. I kepp getting the error Object referenced outside a "With" statement.: The latest way I tried this looks like the following: I have tried placing the AdlibEnable line at various places in the script but it never seems to work regardless. Func GreySubmit() If $oIE then $oIEE = _IEAttach ("Safe Portal", "embedded") $Sub = $oIEE.document.getElementById("FramePage").contentwindow.document.forms.Form1.R_footer_SB.disabled If $Sub = 0 then $oIEE.document.getElementByI("FramePage").contentwindow.document.forms.Form1.R_footer_SB.disabled="True" Endif EndFunc
-
perfect thanks!!!
-
I am trying to loop through all teh objects on a webpage and read in three properties. Based on the values of the properties I then do something. My problem is that the script ends in error if it hits an object that does not have one of the properties i am calling. Here is a snip of the code. for $Obj In $Objs with $Obj $1 = .id $2 = .maxLength EndWith Do stuff with the variables How do I check if an object has given properties?
-
Help finding a form on a complicated website
zasxes replied to JeffJones's topic in AutoIt General Help and Support
This may not be the best way but it worked for me #include <IE.au3> Global $oIE Global $AFrames Global $CountFrames Global $AFrame Global $BFrames Global $BFrame $oIE = _IECreate("https://www.putnam.com/individual/") $AFrames = _IEFrameGetCollection ($oIE) $CountFrames = @extended MsgBox(0, "FramesA " & $CountFrames, "see above") For $i = 0 to ($CountFrames - 1) $AFrame = _IEFrameGetCollection ($oIE, $i) MsgBox(0, "Frame Info for Frame " & $i, _IEPropertyGet ( $AFrame, "locationurl")) Next $BFrames = _IEFrameGetCollection ($AFrame) $CountFrames = @extended MsgBox(0, "FramesB " & $CountFrames, "see above") For $i = 0 to ($CountFrames - 1) $BFrame = _IEFrameGetCollection ($AFrame, $i) MsgBox(0, "Frame Info for Frame " & $i, _IEPropertyGet ( $BFrame, "locationurl")) Next ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; $MainFrame = _IEFrameGetCollection ($oIE, 0) $UpperFrame = _IEFrameGetCollection ($AFrame, 0) $LowerFrame = _IEFrameGetCollection ($AFrame, 1) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; $oTable = _IETableGetCollection ($LowerFrame) $iNumTables = @extended MsgBox(0, "Table Info", "There are " & $iNumTables & " tables on the page") $oForm = _IEFormGetObjByName ($LowerFrame, "login") $Uid = "111111" $oQuery = _IEFormElementGetObjByName ($oForm, "logon") _IEFormElementSetValue ($oQuery, $Uid) -
Accessing IE Objects in Tables in Framesets
zasxes replied to zasxes's topic in AutoIt General Help and Support
I will provide anyone who is willing to help with a test account to log into the website to see the setup first hand. Just email me at zasxes@excite.com -
Accessing IE Objects in Tables in Framesets
zasxes replied to zasxes's topic in AutoIt General Help and Support
Nope that is what I have tried and this is teh error I get >Running:(3.2.2.0):\Program Files\AutoIt3\autoit3.exe "C:\Documents and Settings\Rachel\Desktop\New Folder\22.au3" --> IE.au3 Warning from function _IEFormGetObjByName, $_IEStatus_NoMatch --> IE.au3 Error from function _IEFormElementGetObjByName, $_IEStatus_InvalidDataType --> IE.au3 Error from function _IEFormElementSetValue, $_IEStatus_InvalidDataType +>16:03:10 AutoIT3.exe ended.rc:0 +>16:03:11 AutoIt3Wrapper Finished