daveofgv
Well-known member
Hello all -
First I want to mention that I am not in school, nor have any assignments that require me to search for help with development. I create software at work to help our system be easier (internally).....
With that said -
I need to create a program that allows the user select which labels and text boxes they wish to see on a windows form. There will be a database involved and I will have each text box bound to the database. When the form is opened - all the text boxes (with their associated label) will be present. (just like a regular form for entering first name, last name, box number, box location etc...).
I will have another form that will have check boxes with all the names of each label/textbox name where the user can check which each textbox they want to see on the other form (these will be a My.Settings)... so...
it will kinda look like this:
I am not worried about the above code (if it is incorrect) as I will figure that part out.....
What I do have a question for is if I have 50 or so text boxes and labels on a form and the user checks a check box that is at the bottom of the form - how can I have it rearrange the form and create a nice looking form without text boxes all over the place?
Example:
just for this purpose this is what it will look like "out of the box"

After the user clicks the check boxes to show them visible or not - this is what I get:

And this is what I need:

I am not sure how to put them in order with no spaces between the controls (as there could be 100 or so on the form)....
Also - it would be nice to have the drag and drop effect (I can figure that one out on my own, but do not know how to keep the locations the user drags and drops to save as they close their form)
Thanks in advanced.
daveofgv
First I want to mention that I am not in school, nor have any assignments that require me to search for help with development. I create software at work to help our system be easier (internally).....
With that said -
I need to create a program that allows the user select which labels and text boxes they wish to see on a windows form. There will be a database involved and I will have each text box bound to the database. When the form is opened - all the text boxes (with their associated label) will be present. (just like a regular form for entering first name, last name, box number, box location etc...).
I will have another form that will have check boxes with all the names of each label/textbox name where the user can check which each textbox they want to see on the other form (these will be a My.Settings)... so...
it will kinda look like this:
VB.NET:
If checkbox1.checked = True Then
form1.textbox1.visible = True
Else
form1.textbox1.visible = False
I am not worried about the above code (if it is incorrect) as I will figure that part out.....
What I do have a question for is if I have 50 or so text boxes and labels on a form and the user checks a check box that is at the bottom of the form - how can I have it rearrange the form and create a nice looking form without text boxes all over the place?
Example:
just for this purpose this is what it will look like "out of the box"

After the user clicks the check boxes to show them visible or not - this is what I get:

And this is what I need:

I am not sure how to put them in order with no spaces between the controls (as there could be 100 or so on the form)....
Also - it would be nice to have the drag and drop effect (I can figure that one out on my own, but do not know how to keep the locations the user drags and drops to save as they close their form)
Thanks in advanced.
daveofgv