Ok, so I'm having trouble with using ReDim arrays; which I was told was the way to do this. I'm just not sure where to put it or had to add to the first Integer ((n, n)) for each pass through the function. FYI, the "Dim PropArray(0, 5) As String" is at the very top of the code where the "Option Compare Database" is.
Dim PropArray(0, 5) As String
Public Function ShowBeam()
For Each ctl In [Forms]![frmShelfBuilder]
If Left(ctl.Name, 3) = "Box" Then
If Int(Right(ctl.Name, (Len(ctl.Name)) - 3)) = Me.txtBeamCount Then
If Box1.Visible = False Then
Set rct = ctl
PropArray(0) = rct.Name
PropArray(1) = rct.Visible
PropArray(2) = rct.Height 'Int out
PropArray(3) = rct.Left 'Int out
PropArray(4) = rct.Top 'Int out
PropArray(5) = rct.Width 'Int out
Else
Set rct = ctl
'ReDim Preserve PropArray(n + 1, 5) where "n" is the current number in the row (I think this is were you would add the "ReDim Preserve"?)
PropArray(0) = rct.Name
PropArray(1) = rct.Visible
PropArray(2) = rct.Height 'Int out
PropArray(3) = rct.Left 'Int out
PropArray(4) = rct.Top 'Int out
PropArray(5) = rct.Width 'Int out
End If
End If
End If
Next
I think I'm on the right track. I'm just stuck at not know where to ReDim Preserve the array to add 1 to the first integer. Any suggestions are welcome. Muchacho apreciado!