On Thursday, March 13, 2014 3:59:50 AM UTC-7, Claus Busch wrote:
Hi Howard,
Am Thu, 13 Mar 2014 02:39:19 -0700 (PDT) schrieb L. Howard:
https://www.dropbox.com/s/gjiom5mm30...%20Format.xlsm
got it.
Try:
Sub Randomizer()
Dim a(19) As Variant, b, c, d, e, f
Dim Small As Integer, Big As Integer
Dim i As Long, j As Long, n As Long, k As Long
Small = 1
For n = 2 To 112 Step 22
For k = 3 To 13 Step 2
Big = Small + 19
j = 0
For i = Small To Big
a(j) = i
j = j + 1
Next
b = a: Randomize
d = UBound(b)
For c = 0 To d
e = Int(d * Rnd) + 1
f = b(c): b(c) = b(e): b(e) = f
Next
Cells(n, k).Resize(rowsize:=20) = WorksheetFunction.Transpose(b)
Small = Small + 20
Next
Next
End Sub
Regards
Claus B.
Now that is a work of art!! Not only does it do MORE but there is less code.
Thanks, Claus. Never cease to amaze.
Regards,
Howard