How to set report-margin by code

  • Thread starter Thread starter Niels
  • Start date Start date
N

Niels

Hello Forum,
how can i change the left (and top) page margin of my
report by code. I try to do this by using

Me.Left = 2000

in different events of the report (open, format a
range ...) but I get always the errormessage "Property was
read only and could not change".

Thanks in advance for any help.
Niels
 
Hello Forum,
how can i change the left (and top) page margin of my
report by code. I try to do this by using

Me.Left = 2000

in different events of the report (open, format a
range ...) but I get always the errormessage "Property was
read only and could not change".

Thanks in advance for any help.
Niels

You can set the report's margins using code if you open the report by
code in design view.
See the PrtMip Property in VBA help.

Note:
The PrtMip property setting is read/write in Design view and read-only
in other views.
 
Back
Top