I have set up am array to select specific cells based in the value of variable X, which works just fine. As I am going to be using this code several times I would prefer to use the call function for this in the middle of a loop. The problem is when I call the new macro, X gets reset to 0.