Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Moving a box at runtime

Status
Not open for further replies.

Len58

Programmer
Sep 25, 2009
2
CA
I have a box on the report footer. I want to move it to the right depending on a grand total. How can I do this? I have tried the move method of the control, but it is not working for me. I don't get an error, the box moves, but regardless of the number it always moves to the same spot.

Thanks.

ie:
Box64.move(1400)
 
Try changing values for the Top & Left properties.

Cogito eggo sum – I think, therefore I am a waffle.
 
There are no Top and Left properties in the reportfooter on Format event. This is my problem.

Thanks.
 
You would use code in the On Format event of the section containing the box. The Grand Total should also be bound to a control in the same section. The code might look like:
Code:
  If Me.txtGrandTotal >= 1000 Then
      Me.CtrlMyBox.Right = 7200 ' about 5 inches
  End If

Duane
Hook'D on Access
MS Access MVP
 
There are no Top and Left properties in the reportfooter

These are properties of the control, not the section.

Cogito eggo sum – I think, therefore I am a waffle.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top