Jump to content

AutoIt Error: Array variable has incorrect number of subscripts...


Smart
 Share

Recommended Posts

Hi, i've been getting this error on my coworker's computer recently.

I took a print of it: '>

It happens at the application startup, the application wasn't coded by us, so we can't debug it...

It happens only with his computer, could that be some windows problem? He has windows 8.1, i've tested on another windows 8.1 computer and it works fine, i've tested on multiple windows 7's and it works fine, only on his computer apparently does that fail.

From the error itself i would assume (although i don't code AutoIt at all.) it was an application problem, but since every other computer works, i started to think it was something more severe... since i google'd autoit has no dependencies, only windows system dll's (that proves i seriously know nothing about it... :P) .

I thought of system restore, but he has no restore points available...

What can we do? How can we know what's really causing it? Could it be some specific windows dll?

Can sfc /scannow help?

Link to comment
Share on other sites

This appears to be the consequence of a badly written script - or possibly one which was never intended to be used on a different computer. Since we cannot see the contents of the script, and decompilation of the executable is against the AutoIt licence, you are really quite stuck. Unless you have a copy of the original script there is nothing anyone can do apart from rewrite the program from scratch, and doing so may not be worth the effort.

What does the program do and how important is it?

Edited by czardas
Link to comment
Share on other sites

It is a very clear AutoIt error, indicating an error by the developer of the script. Given the location of the script file (file called "b" in a folder intended for temporary content) and the weird strings in the code, it looks like autogenerated script code, i.e. AutoIt code generated by some other application (which we know nothing about with this information).

The code displayed in the error is intended to remove carriage returns from a string.

What is the application you are trying to start up?

Roses are FF0000, violets are 0000FF... All my base are belong to you.

Link to comment
Share on other sites

The application is an checker of some sort (i don't know) that is to be run before it starts another application.

But if it was really the application's fault, wouldn't it fail on all computers? I mean, the application wasn't made to be run on my computer, and it runs, it also runs on every other computer i've tested it, with the same or different OS, it just doesn't run on that particular one... and i don't know AutoIt and apparently decompilation is against it's policy as you said.

I'm just puzzled as it not working at that specifically un-related computer.

As i searched AutoIt has no dependencies other than windows itself, my thought was exactly that, but how can i know for sure?

Link to comment
Share on other sites

But if it was really the application's fault, wouldn't it fail on all computers?

 

Impossible to tell without knowing more about the application in question. If the application indeed auto-generates some AutoIt code and then runs it, which I still assume given what we know now, than apparently it's doing it based on some environmental things which are then, again apparently, different for this machine. Maybe the developer of the application that generates the AutoIt code forgot to encode strings that are pushed into that AutoIt code by escaping doublequotes, for instance.

Edited by SadBunny

Roses are FF0000, violets are 0000FF... All my base are belong to you.

Link to comment
Share on other sites

Impossible to tell without knowing more about the application in question. If the application indeed auto-generates some AutoIt code and then runs it, which I still assume given what we know now, than apparently it's doing it based on some environmental things which are then, again apparently, different for this machine. Maybe the developer of the application that generates the AutoIt code forgot to encode strings that are pushed into that AutoIt code by escaping doublequotes, for instance.

 

But i'm almost positive (can't be sure) that the only differenciation it might do is between operating systems, but i've tested this on another one (windows 8.1) and it works...

I don't have the script source, nor can i get it i'm afraid, but this is puzzling for me.

I understand the error is specific to the script, but i can't understand how, yeah... my "almost positive" might be it, but i'd say it isn't.

Link to comment
Share on other sites

There is something unique to that environment, obviously.  For example, maybe the script is designed to pre-process Word files and there are none.  Since you are not giving up any info about what the script does, we can only guess.

Forum Rules         Procedure for posting code

"I like pigs.  Dogs look up to us.  Cats look down on us.  Pigs treat us as equals."

- Sir Winston Churchill

Link to comment
Share on other sites

You are trying to access a array component futher the real array range. This happens when the code doesnt test it byself to avoid it.

By example:

Local $aArray=StringSplit('gg,hh',',')
For $i=1 To 3
   MsgBox(0,'Test',$aArray[$i])
Next
 
Gives this error, and must be used the index:
 
Local $sString='gg,hh'
Local $aArray=StringSplit($sString,',')
For $i=1 To $aArray[0]
   MsgBox(0,'Test',$aArray[$i])
Next
 
In you script, witch is deleting linefeeds (may be readed from a textfile?), the component $x234234xx[$rwererer+1]:   $rwererer+1  >  bounds of  $x234234xx.
Edited by zalomalo

My english shucks, i know it.

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...