UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Move Elements In A Report By Code, Access 2007    
 
   
alwazeer
post Feb 16 2017, 10:41 PM
Post#1



Posts: 13
Joined: 4-October 15



Hi Every one

I have a report containing text boxes I want to be moved by the code as shown in the example
I use the traditional method
Is there another way?
Her what i do

CODE
Private Sub Report_Open(Cancel As Integer)
Dim xx
xx = 1440
Dim wd
wd = 0.22 * xx


Dim i
For i = 1 To 24
Me("a" & i).Width = wd
Next i
'=====================

Me.a24.Left = FrstM.Left
Me.a23.Left = a24.Left + wd
Me.a22.Left = a23.Left + wd
Me.a21.Left = a22.Left + wd
Me.a20.Left = a21.Left + wd
Me.a19.Left = a20.Left + wd
Me.a18.Left = a19.Left + wd
Me.a17.Left = a18.Left + wd
Me.a16.Left = a17.Left + wd
Me.a15.Left = a16.Left + wd
Me.a14.Left = a15.Left + wd
Me.a13.Left = a14.Left + wd
Me.a12.Left = a13.Left + wd
Me.a11.Left = a12.Left + wd
Me.a10.Left = a11.Left + wd
Me.a9.Left = a10.Left + wd
Me.a8.Left = a9.Left + wd
Me.a7.Left = a8.Left + wd
Me.a6.Left = a7.Left + wd
Me.a5.Left = a6.Left + wd
Me.a4.Left = a5.Left + wd
Me.a3.Left = a4.Left + wd
Me.a2.Left = a3.Left + wd
Me.a1.Left = a2.Left + wd
End Sub

Attached File(s)
Attached File  TestDBR.zip ( 16.83K )Number of downloads: 4
 
Go to the top of the page
 
ranman256
post Feb 17 2017, 06:13 AM
Post#2



Posts: 786
Joined: 25-April 14



Use report designer.
There's no need to move boxs by code.

Or make another report via SaveAs.
Go to the top of the page
 
alwazeer
post Feb 17 2017, 09:25 AM
Post#3



Posts: 13
Joined: 4-October 15



ohyeah.gif
Thanks

I have found the solution

Many Thanks for all
Go to the top of the page
 


Custom Search
RSSSearch   Top   Lo-Fi    13th December 2017 - 11:51 AM