Jump to content

Recommended Posts

Posted

Hi All,

I am beginner to autoit. Trying to automate local host. I can able to read the login page of site by using _IEBodyReadText but after login i cant able to read text using _IEBodyReadText. It is returning value 0 at line number 17.Please help me on this. Thanks in advance

Here my code

1. #include <IE.au3>

2. $oIE = _IECreate ("http://171.12.10.13:8080")

3. $sText = _IEBodyReadText ($oIE)

4. MsgBox (0,"Display",$sText)

5. sleep(1000)

6. ; Matching the string username in login page

7. $a=StringRegExp ( "$sText","username" )

8. if ($a ==0) Then

9. send ("admin")

10. sleep("100")

11. send ("{tab}")

12. send ("admin")

13. send ("{Enter}")

14. EndIf

15. _IELoadWait($oIE);

16. $Text = _IEBodyReadText ($oIE)

17. MsgBox(0, "Body Text", $Text)

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
×
×
  • Create New...