Jump to content
Sign in to follow this  
snomy

2d array done, now need to take it further

Recommended Posts

snomy

OK so ive got the 2d array below, works like a treat when displaying the values into a msgbox, however i want the first time it runs to set a control id, then second time to insert text into that control.

As you can see my feeble attempt is commented out!

Dim $arGrid[2][1] = [["[CLASS:EDIT; INSTANCE:1]"], ["Samosa"]]

For $y = 0 To UBound($arGrid,2)-1;

For $x = 0 To UBound($arGrid,1)-1;

; ControlSetText("Login", "", $arGrid[$x], $argrid[$y] ")

MgBox(0,"Array element "&$x&","&$y, $arGrid[$x][$y])

Next

Next

Any ideas and help would be great. Its driving me bananas, and having read through the entire AutoIT help files for every occurrence of array, im still at a lost end!!!

cheers.

Share this post


Link to post
Share on other sites
BrettF

OK so ive got the 2d array below, works like a treat when displaying the values into a msgbox, however i want the first time it runs to set a control id, then second time to insert text into that control.

As you can see my feeble attempt is commented out!

Dim $arGrid[2][1] = [["[CLASS:EDIT; INSTANCE:1]"], ["Samosa"]]

For $y = 0 To UBound($arGrid,2)-1;

For $x = 0 To UBound($arGrid,1)-1;

; ControlSetText("Login", "", $arGrid[$x], $argrid[$y] ")

MgBox(0,"Array element "&$x&","&$y, $arGrid[$x][$y])

Next

Next

Any ideas and help would be great. Its driving me bananas, and having read through the entire AutoIT help files for every occurrence of array, im still at a lost end!!!

cheers.

Do you mean the first element of $i to = Control then the Second element of $i to = Text?

Share this post


Link to post
Share on other sites
snomy

yeah thats exactly what i mean, can it be done?

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  

×