Sign in to follow this  
Followers 0
DoctorSLO

StringRegExp problem in vista

4 posts in this topic

#1 ·  Posted (edited)

Hi.

I have problems with my script ... When I run it at my computer, everything going well, but when I run on someone other computer with Vista, I got error :D

The error comes from stringregexp :

$ie = _IECreate("http://speed.travian.si", 0, 0)
            $html = _IEBodyReadHTML($ie)
            $muca = StringRegExp($html, 'class="fm fm110" maxLength=15 value=(\w+) name=(\w+)', 1)
            $offime = $muca[1]
            $pw = StringRegExp($html, 'class="fm fm110" type=password maxLength=20 value="" name=(\w+)', 1)
            $offgeslo = $pw[0]
            $ime = _IEGetObjByName($ie, $offime)
            $geslo = _IEGetObjByName($ie, $offgeslo)
            $prijava = _IEGetObjByName($ie, "s1")

In VISTA i got error here that offime is not declared variable ... in XP working fine ...

On the post below is complete code

Edited by DoctorSLO

Share this post


Link to post
Share on other sites



sry for duble post post :D too long post

so here is my code:

sry too long .. so I upladed it

Farmer_v0.51.au3

Share this post


Link to post
Share on other sites

You don't need to use StringRegExp when using IE.au3 library. You can get almost any type of information using the _IE* functions or the object properties/methods. The problem also is that you're not checking if StringRegExp returns an array variable before using the variable's subscripts which may not exist. If you can post the error as it outputs to the console it may help.

Share this post


Link to post
Share on other sites

I get :

Subscript used with non-Array variable.:

$offime = $muca[1]

$offime = $muca^ ERROR

Share this post


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
Sign in to follow this  
Followers 0