Jump to content
Sign in to follow this  

Array Question

Recommended Posts


Dim $aArray[2]

$aArray['a'] = "AA"

$aArray['b'] = "BB"

Msgbox(0,'Array:' , $aArray['a']) ;;; return "BB"



<script language='javascript'>


var arr = new Array();

arr['a'] = "AA";

arr['b'] = "BB";

alert(arr['a']); // return "AA"



--------------php Script--------------


$arr = array(

"a" => "AA",

"b" => "BB",


echo $arr["a"]; // return "AA"


Share this post

Link to post
Share on other sites

AutoIt does not convert characters to numeric values like php. In fact both 'a' and 'b' will evaluate to zero in this usage.


Dim $aArray[2]

$aArray['a'] = "AA" ;assigned to element 0

$aArray['b'] = "BB" ;overwrites previous assignment

For $i = 0 to 1

MsgBox(4096,$i, $aArray[$i])


Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!

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  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.