1. there is no screenupdating in de "do...Loop", but as soon as a solution is found, that one is shown. Look where i wrote both lines.
2. Application.StatusBar = False if you omit that one, when the macro stops, the statusbar 'll still show "solution 100" (or another number) and that's not an error but it isn't nice.
3.
the row just above says where you want to write your data, but with this one, we write a header just above, so the offset is -1 (1 row above) and the size is 1 row and also 4 columns (but that's the same, so you don't have to repeat that).
4. If you want to exchange columns, you have to do that in
and then in the header (see 3) and if the sortcolumn changes make that ".cells(1)" for example ".cells(2,1)" for the 2nd column. There is no header because with that "with...end with" construction you only look at the range Range("O2").Resize(MyArray.Count, 4), so the header isn't included.
Bookmarks