change the image of an UIImageView in an image array
i have a series of images in an image array, 

    UIImageView *dot[6][4];

and i put the images on the screen in one method, and then i change the image in another method, but i doesn't work?

    -(void)methodA{
          for (int x = 0; x<6; x++) {
        for (int y=0; y<4; y++) {
            
           
            
            dot[x][y] = [[[UIImageView alloc] initWithFrame:CGRectMake(((side+padding)*x)+23,   ((-(side+padding))*y)+247, side, side)] autorelease];
            
            dot[x][y].image = [UIImage imageNamed:@"off.png"];
            
            
            if ((x==0 && y==2) || (x==0 && y==3) || (x==2 && y==3) || (x==4 && y==3)) {
                
            }else{
                [self.view addSubview:dot[x][y]];
            }
            
            
            
        }
    }
    -(void)methodB:(int)x Y:(int)y{
          dot[x][y].image = [UIImage imageNamed:@"on.png"];
    }

thanks.
change the image of an UIImageView in an image array
===

i have a series of images in an image array, 

    UIImageView *dot[6][4];

and i put the images on the screen in one method, and then i change the image in another method, but i doesn't work?

    -(void)methodA{
          for (int x = 0; x<6; x++) {
        for (int y=0; y<4; y++) {
            
           
            
            dot[x][y] = [[[UIImageView alloc] initWithFrame:CGRectMake(((side+padding)*x)+23,   ((-(side+padding))*y)+247, side, side)] autorelease];
            
            dot[x][y].image = [UIImage imageNamed:@"off.png"];
            
            
            if ((x==0 && y==2) || (x==0 && y==3) || (x==2 && y==3) || (x==4 && y==3)) {
                
            }else{
                [self.view addSubview:dot[x][y]];
            }
            
            
            
        }
    }
    -(void)methodB:(int)x Y:(int)y{
          dot[x][y].image = [UIImage imageNamed:@"on.png"];
    }

thanks.