473,657 Members | 2,380 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Set report margins in code?

Ron
Hi All,

I'm using A2K and need to print a specific pre-printed form. I know that
once I have that report on a particular computer screen I can select "Page
Setup" and change the margins to get the different fields I'm printing where
I need them to print (fine tuning type of changes as all the controls are
basically printing where needed--say on a pre-printed check that's inserted
into the printer). However, if I then have another user try to print that
same check on THIER printer, the margins aren't set correctly and it prints
everything off either high/low and/or left/right by whatever.

I know that I could have a table on each users system with a record for
whatever margin settings would be needed (once set up by the user or me or
whatever). But can I get those margin settings to be used by a report?
Where do I stick them if that's possible.

Yeah, I know I can set it at the time of printing...but I don't want my
USERS to do that. Plus, I see down the road I'll want to compile all this
and use a runtime version...so the user wouldn't have access to that Page
Setup area anyway.

Possible?
ron
Nov 10 '07 #1
1 6498
"Ron" <ro************ ********@verizo n.netwrote in message
news:oMkZi.1342 $VB6.1261@trndd c06...
Hi All,

I'm using A2K and need to print a specific pre-printed form. I know that
once I have that report on a particular computer screen I can select "Page
Setup" and change the margins to get the different fields I'm printing
where I need them to print (fine tuning type of changes as all the
controls are basically printing where needed--say on a pre-printed check
that's inserted into the printer). However, if I then have another user
try to print that same check on THIER printer, the margins aren't set
correctly and it prints everything off either high/low and/or left/right
by whatever.

I know that I could have a table on each users system with a record for
whatever margin settings would be needed (once set up by the user or me or
whatever). But can I get those margin settings to be used by a report?
Where do I stick them if that's possible.

Yeah, I know I can set it at the time of printing...but I don't want my
USERS to do that. Plus, I see down the road I'll want to compile all this
and use a runtime version...so the user wouldn't have access to that Page
Setup area anyway.

Possible?
ron
Take a look at the Printer object in help. Does exactly what you want.

You need to use the Printer property of your report.

Nov 10 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2218
by: Maurice Mertens | last post by:
Hello, I'm trying to print a report to the printer but somehow it doesn't take the margins I set. I want the report to have a margin of 0.7 cm (397 twips), so in code I use the following: dim rpt as New rptOverview
1
1918
by: Steve G | last post by:
Hi, I am having the following issue: I have a report which I use to create an ASCII file. Its not necessary to print the report since its going to a file for on screen view only. The problem is there is no way to get around the page setup which requires a printer and margins for the report. When I export with "output to..." text, there are line breaks where the page margins are. It won't allow margins less than 0.25" or paper size...
6
8175
by: Salad | last post by:
Hi: I have a Bill of Lading template from the printer that I saved as a BMP. I created a new report and in the report's picture property told it the BMP file name. It brought the image in just fine. I then placed the fields in the report. Then I previewed the report. The picture resized or something and all of my nice fields were no longer in the same position. It didn't make any difference if I selected Crop, Zoom, or...
0
916
by: Tom Hoogeboom | last post by:
I am trying to give my clients the option to preview a Crystal report using the Crystal ReportViewer control on a web page, or sending the report directly to their default printer, so far without success. The code I am using follows: Public oReport As CrystalDecisions.CrystalReports.Engine.ReportDocument 'PrintDirect is boolean parameter read from page header Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs)...
7
27646
by: steve | last post by:
Hi All I need to change text in a Report Viewer document at runtime It is just the heading I want to change to match what the user has chosen as the Report to view How do I access the textbox in "GymMaster.Memberships.rdlc" (below) to change the text sql = "select * from members order by surname"
7
21736
by: steve | last post by:
Hi All I have created rdlc files and when I load them into Report Viewer at run time they appear OK If I click on 'Print layout' button on Report Viewer the view again appears acceptable If I click on 'Page setup' button the margins left & right are not what I set on the rdlc file at design time (1.5cm) they are 5.9mm
0
1218
by: vinamb2006 | last post by:
yes,Iam using button onclick event. the code is as under 'PrintReport() prtdoc.PrinterSettings.PrinterName = comboInstalledPrinters.SelectedItem.Text Dim strDefaultPrinter As String = prtdoc.PrinterSettings.PrinterName 'Dim rap As New CrystalDecisions.CrystalReports.Engine.ReportDocument() 'report1.Load("c:\inetpub\wwwroot\ticket\printrpt.rpt") Dim margins As PageMargins
1
2134
by: pdm | last post by:
I think a well known access problem. If you customize the default margins of a report they doesn't remain fixed. The margins jumps back to the default margins for reports (which are sometimes to width) when you open it again or change something on the desing of the report. thanks for a help to fix this awkward problem or margin.
9
4884
by: Martian7 | last post by:
Hello, I have been having a problem with my database lately. Everything seems to be working well accept the reports. Everytime I open the report I have to reformat the report margins to get everything to fit on one page. I was wondering first if it is even possible to create an access macro or a combination of a macro and a module to run a format on the report when on the time the report opens so that I can view everything on one page. I...
0
8825
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8503
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8605
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6164
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5632
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4152
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4304
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1955
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.