Solved

The code to print a form to a printer

Posted on 1999-01-22
7
123 Views
Last Modified: 2010-05-03
How to print any form to a printer ?
With or without graphics !
The sulution must work on any computer and on any printer. If it prints in color - Fine, but not necessery.

My own test doesn't works on screen having a higher resulution than VGA !
0
Comment
Question by:pgg
  • 3
  • 2
  • 2
7 Comments
 
LVL 10

Accepted Solution

by:
caraf_g earned 100 total points
ID: 1470109
PrintForm
0
 
LVL 10

Expert Comment

by:caraf_g
ID: 1470110
Sorry for the brief answer:

In a Form module, to print the actual form
PrintForm

In any module to print any form
FormVariable.PrintForm
0
 
LVL 1

Expert Comment

by:MAVERICK
ID: 1470111
I tried a version using the paintpicture method....
Capture the form as a picture ..... then use printer.paintpicture.

regards
Jon

0
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.

 
LVL 1

Expert Comment

by:Johnn
ID: 1470112
Hey MAVERICK...where did you get your solution?  I posted that same one a few days ago..
0
 
LVL 1

Expert Comment

by:MAVERICK
ID: 1470113
From WATY...

Johnn: As promised I checked your solution .... It needs alittle more work to do with the window's handle .... If u took the get window handle code from waty ...It'd probably work...

No offense but... waty has some of the best written code around...



0
 
LVL 1

Expert Comment

by:Johnn
ID: 1470114
Maybe so...I was only doing it off the top of my head.  I never actually tested it(I leave this up to the questioner as I'm not being compensated for it(at least financially) as well as I beleive they need to "do it" themselves to really learn and understand the solution.

John
0
 
LVL 1

Expert Comment

by:MAVERICK
ID: 1470115
Thats one way to look at it .... but API programming is difficult at the best of times..... As I understand... using standard modules is a common time saver for programmers..

In any case .... pgg refer to http://www.experts-exchange.com/Q.10118894 for the capture codes.....



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

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

910 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

21 Experts available now in Live!

Get 1:1 Help Now