Android Question Multi Dimension Array values predefining

sorex

Expert
Licensed User
Hello,

Is there a way predefine a multi dimentional array with some preset values without using code?

I tried

B4X:
dim mda(8,8) as int
mda=Array as int ( (0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0),(0,0,0,0,0,0,0,0))
but it doesn't seem to accept it.
 

sorex

Expert
Licensed User
What about a special keyword for this kind of thing?

Array2 or MDArray ?

I currently changed it to a single dimension with extra math to bypass the problem.
 
Top