I'm assuming that I don't understand your problem, so it is unlikely that what I said above is a solution for you. Still, I'm trying to get a code example that does not work for you so that we can analyze it for the solution. So, lets start with the above. Does it resize properly for you?
Note, you might want to subtract 100 so you can be sure that the lower right corner is not off the form. But then don't shrink down your form to much for this test (unless you take it out or put in a limiter IF statement of some sorts).
Private Sub Form_Resize()
Text1.Move 0, 0, Me.ScaleWidth - 100, Me.ScaleHeight - 100
End Sub
Main Topics
Browse All Topics





by: EnladePosted on 2004-11-20 at 09:12:13ID: 12634413
You need to trap the resize event for the form and then resize each control within that event. For instance, create a form and then put a textbox control on it (call it Text1). Then add the following code to the form code and run. Then resize the form and watch the textbox resize.
Private Sub Form_Resize()
Text1.Move 0, 0, Me.ScaleWidth, Me.ScaleHeight
End Sub