| re: error creating windows handle in usercontrol
Just use only ONE check box and move it from place to place when a user
selects a cell. Example: cell 1,1 is active (where the check box is located)
then when the user selects another cell like 30, 30 move the check box to
that cell. You can hold all the grid information in an array of some kind.
"terrasamba" <terrasamba@hotmail.com> wrote in message
news:160601c38998$42550bd0$a101280a@phx.gbl...[color=blue]
> Hi guys, done it again, got myself stuck ... this time on
> the following issue:
>
> I have made a user control that more or less simulates a
> grid.
>
> You can set the amount of columns,rows, cell size, colors
> etc. This works fine.
>
> This user controls simulates a grid by placing checkboxes
> on the usercontrol. The checkbox contains all the
> existing events and properties that I need.
>
> But when I size it to the maximum dimentions that I
> need (100 rows by 100 columns) this will create 10.000
> controls,
> besides that it is slow .... even with suspendlayout ....
> after about 5000 it looks like I reached the maximum. No
> more handles can be obtained ... and generates an error.
>
> Is there a solution for this?
> What is the maximum amount of controls you can put on a
> usercontrol or any control?
> Anybody got bright ideas to obtain simular functionality?
> (a grid where one or more cells can be selected and that
> can receive drag-drop events and host images)
>
> Thanx for any help,
>
>
>
>
>
> The gap between theory and practice is not as wide in
> theory as it is in practice.
>[/color] |