What you want to do requires a few tricks.
For instance:
Maipulate[ f[ Array[ a, exp], ...], ...]
and similar constructions do not work (and are explained in the documents), because a[_] are not explicit in the expression, so it is difficult to have a variable number of controls. The solution I found is:
Manipulate[ f[
Another problem is that the design
Control@ ( .
two-dimensional splitting does not allow itself, therefore we should use both Control @ syntax parameters (Control @ and {...}), which are not documented.
Other troubles you can find in the code below.
So:
soData = {{"col01", "col02", "col03", "col04", "col05", "col06", "col07", "col08", "col09", "col10"}, Range[1, 10], Range[11, 20], Range[21, 30], Range[31, 40]}; perRow = 5; colsel = (# -> Graphics[{#, Disk[]}, ImageSize -> 15]) &/@ColorData[1, "ColorList"]; s[x_] := Style[x, Black, Bold, 12]; ct = ControlType -> PopupMenu; Manipulate[ DataSampleXX[soData, linesNumber, Sort@Join [Sequence @@ #], color1, color2, color3], Row[ {Column[ { Control@ {{linesNumber, 2, s@ "Lines"}, Range[2, Length@soData [[All, 1]] - 1], ct}}], Spacer[20], Column[ { Control@ {{color1, colsel[[1, 1]], s@ "Color 1"}, colsel, ct}, Control@ {{color2, colsel[[2, 1]], s@ "Color 2"}, colsel, ct}, Control@ {{color3, colsel[[3, 1]], s@ "Color 3"}, colsel, ct}}]}], Evaluate[ Sequence @@ MapThread[{{#1, {}, ""}, #2, ControlType -> TogglerBar} &, {#, Partition[Rule @@@ Transpose[{Range[10], soData[[1]]}], perRow]}]]] &@ Array[a, Length[soData[[1]]]/perRow]
