Redefining the size of dimGrid

Is it possible to change the size of dimGrid throughout the program. dimGrid=(x,y) doesn’t work. Thanks.

dimGrid.x = __;

dimGrid.y = __;

??

Could work, I ended up using dimGrid=dim3(x,y). Thanks anyway :)