spacing in data reports

satyam
03-22-2002, 02:18 AM
My data report displays some text in letter format. There are six text boxes to display the text from database. I gave equal spacing between these text boxes ( text1.Top = 1000, Text2.Top=1300, Text3.Top=1600 ....). When a text box's text exceeds the report width then it dynamically expands to next line.
My problem is if Text1 expands to accomodate the second line the other text boxes are not moving equally towards down to maintain the equal spacing between the lines. Is it possible to relocate the controls at run time just like we can do in forms.
(ex: Form1.Text2.Top=7500)? Please help
:)

AndreRyan
03-22-2002, 03:35 AM
Try this:

Private Sub Form_KeyPress(KeyAscii As Integer)
If Len(Text1.Text) >= CreateNewLineLength then
Text1.Multiline = true
Text1.Height = Text1.Height * 2
Text2.Top = Text1.Height + Text1.Top + SpaceBetweenBoxes
...
End If
End Sub

satyam
03-22-2002, 06:17 AM
Thank you very much sir.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum