in the form_resize event, you should be able to simple adjust the properties of the controls you want to mess with. For example, when the form gets resized (maximized) you can figure out the percentage and ratio, and use the .top, .left, .width and .height properties of any control:
But, do I have to do it manually for each control? is there an option to do them all at once?
Another point that I did not specify, is that the form_resize event of the form is executed when the form is loaded, how do i verify if the form is maximized, do i have to compare the actual width with the original size or is there another way?
if form1.state = vbmaximized then
' /* Code For Maximized Form */
However, vbmaximized MIGHT NOT be a constant, but numbers work, I believe 2 is maximized, but I could be mistaken. Also, The property might not be state, it might be style or something similar. So, Just test the property to find out if it's maximized or not.
As for adjusting the controls, you could do a loop of the control's collection, but you are going to be using a lot of comparisions to figure out the type of control you are working with. A Textbox doesn't have a caption property, for example, so you need to be aware of the differences involved with the properties of certain objects. I believe you can do a simple:
for each XCtrl in Controls
Then you could adjust them all with their properties in a simple for each loop. I hope this helps some.