Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Printing Question

Posted on 1998-08-31
2
Medium Priority
?
165 Views
Last Modified: 2011-04-14
I have to write a report which 2 pages: the first one is the customer record, and the second one is a table with all the activities of the customer in the last month(kind of a grid table). I have no problems with the first page, but when I tried to deal with second page, i could figure out how can I align and limit the size of the fields so all the rows for a specific colimn will start on the same X. I tried to use the currentX/Currenty but it didn't work.
Can someone help me, please

Alon
0
Comment
Question by:oak022097
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 12

Accepted Solution

by:
mark2150 earned 180 total points
ID: 1432155
Umm, as you print, don't advance the cursor:

Printer.print "col1";
printer.currentx = ... set to column two
printer.print "col2";

The ; at the end of the line will prevent the print cursor from advancing.

You can also force the issue:

TempY = Printer.CurrentY
Printer.Print "Col1"
Printer.CurrentY = TempY
Printer.CurrentX = Col2X
Printer.Print "Col2"

Same technique lets you right align. Say you had to print something at 5" that would
place you at 7220 twips in from the left.

txt = "Text to print Right"
Printer.CurrentX = 7220 - text.width(txt)
Printer.Print Txt

etc.

Remember text prints DOWN and to RIGHT of CurrentX/CurrentY and that there are 1440 twips in one inch. (1 inch = 6 Picas = 72 Points = 1440 Twips)

0
 
LVL 14

Expert Comment

by:waty
ID: 1432156
You could use my Print Preview OCX. It does everything :

 Web Site : http://www.geocities.com/ResearchTriangle/6311/ 
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question