Solved

printing contents in textbox

Posted on 2002-04-10
2
208 Views
Last Modified: 2010-05-02
i have to print the contents of the textbox, which i am able to do it with the help of print dialog box.
but the problem is there is no margin in printing. so, hoe do i set the margin in the paper so the contents are little indented and printed.
0
Comment
Question by:RanjiniPraba
2 Comments
 
LVL 4

Expert Comment

by:TomLaw1999
ID: 6932098
Try something like this
if printer.currentX < 1000 then printer.currentx = 1000

0
 

Accepted Solution

by:
lschuele earned 15 total points
ID: 6932134
If you are using the Printer object:

Use the Printer's scale properties to set margins. Set the properties so the position (0, 0) is mapped to where you want the margins. For example, the following code makes the left margin 0.5 inches and the top margin 0.75 inches. The factor of 1440 converts inches into twips.

Printer.ScaleLeft = -0.5 * 1440
Printer.ScaleTop = -0.75 * 1440
Printer.CurrentX = 0
Printer.CurrentY = 0

Printer.Print Me.Text1.Text
Printer.EndDoc
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
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…

930 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now