Jump to content

Arrays in Arrays


Sypher
 Share

Recommended Posts

Hi Folks,

I am working on a little tool that automates some of the tasks i normally have to do by hand.

The big problem is that i'm stuck at creating multidimensional arrays.

Dim $ResultArrayoÝ÷ Ù«­¢+Ù}ÉÉå%¹ÍÉÐ ÀÌØíIÍÕ±ÑÉÉä°À°}ÉÉå
ÉÑ ÀÌØí±¥¹°ÀÌØí±¥¹¬°=ÙÉÉÕ±È ÀÌØí±¥¹¤¤¤

The results of that is the following (made with _ArrayDisplayTree)

Posted Image

It just crashes... I've tried lots of various code, but this is just pretty annoying :)

The Array is created from within a for-loop that reads the RSS feed, and the data i like are being put in the array.

The thing i am trying to do - but well, without $ResultArray[1][0] i can't do much - is to cross-match the array content with another array, and dump all the non-matching ones (think: watchlist).

Anyhow, can anyone please point me in the good direction? Thanks!

Edited by Sypher
Link to comment
Share on other sites

Hi,

consider Array2d in my sig?

eg

; arrayexampleinsert.au3
#include<array2D.au3>
local $ar_Created2D[1][1],$asControls = StringSplit(WinGetClassList("", ""), @LF)
_ArrayDisplay($asControls,"$asControls")
local $arGrid[2][4] = [["Paul", "Jim", "Richard", "Louis"], [485.44, 160.68, 275.16, 320.00]]
_ArrayDisplay($arGrid,"$arGrid")
local $arGrid0[4] = ["Paul", "Jim", "Richard", "Louis"]
_ArrayDisplay($arGrid0,"$arGrid0")
local $arGrid1[4] = [485.44, 160.68, 275.16, 320.00]
_ArrayDisplay($arGrid1,"$arGrid1")
_ArrayInsert2D( $ar_Created2D, $arGrid0, 0)
_ArrayInsert2D( $ar_Created2D, $arGrid1, 0)
_ArrayDisplay($ar_Created2D,"$ar_Created2D")
Best, randall Edited by randallc
Link to comment
Share on other sites

Or even...

; arrayexampleinsert.au3
#include<array2D.au3>
local $ar_Created2D[1][1],$arGrid0[4] = ["Paul", "Jim", "Richard", "Louis"]
local $arGrid1[4] = [485.44, 160.68, 275.16, 320.00]
local $arGrid2[4] = [1,2 ,3, 4]
for $a=0 to 1
_ArrayInsert2D( $ar_Created2D, eval("arGrid"&$a), 0)
_ArrayInsert2D( $ar_Created2D, eval("arGrid"&$a), 0)
next
_ArrayInsert2D( $ar_Created2D, $arGrid2, 2)
_ArrayDisplay($ar_Created2D,"$ar_Created2D")
Randall Edited by randallc
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...