471,108 Members | 1,278 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,108 software developers and data experts.

Problems w/ Printing under XP

Up until now I have been able to avoid using Common Dialog by accessing printers
directly. This is no longer possible, so-

Using VB5 under XP Home Edition. I use the Common Dialog functions to select a
printer and output my data.

1. If I am in the VB5 IDE, the printer output appears to be non-proportional and
looks perfect because it all lines up.

2. If I am running the compiled program by itself, the printer output uses a
smaller font which apparently is proportional and the result is very ragged
looking as nothing lines up.

3. When I tried using the Common Dialog Show Font method, I got an error message
saying that no fonts were installed. (Word for Windows lists dozens of fonts so
they must be installed and all of them appear to be TrueType.)

Does anyone has any ideas about what else I might try?
Val Mehling
valjm16@DELETE_THISearthlink.net

XRL (Extreme Racing League) Info
http://extremeracingleague.com/
Jul 17 '05 #1
3 2575
> Up until now I have been able to avoid using Common Dialog by
accessing printers
directly. This is no longer possible, so-

Using VB5 under XP Home Edition. I use the Common Dialog functions to select a printer and output my data.

1. If I am in the VB5 IDE, the printer output appears to be non-proportional and looks perfect because it all lines up.

2. If I am running the compiled program by itself, the printer output uses a smaller font which apparently is proportional and the result is very ragged looking as nothing lines up.

3. When I tried using the Common Dialog Show Font method, I got an error message saying that no fonts were installed. (Word for Windows lists dozens of fonts so they must be installed and all of them appear to be TrueType.)

Does anyone has any ideas about what else I might try?


You have to tell the control which Fonts you want via the Flag property.
Assuming you named the control CommonDialog1 (the default)...

For Screen Fonts only
=======================
CommonDialog1.Flags = cdlCFScreenFonts

For Printer Fonts only
=======================
CommonDialog1.Flags = cdlCFPrinterFonts

For Both
=======================
CommonDialog1.Flags = cdlCFScreenFonts Or cdlCFPrinterFonts

Rick - MVP

Jul 17 '05 #2
On Wed, 25 Aug 2004 12:11:18 -0400, "Rick Rothstein"
<ri************@NOSPAMcomcast.net> wrote:
Up until now I have been able to avoid using Common Dialog by

accessing printers
directly. This is no longer possible, so-

Using VB5 under XP Home Edition. I use the Common Dialog functions to

select a
printer and output my data.

1. If I am in the VB5 IDE, the printer output appears to be

non-proportional and
looks perfect because it all lines up.

2. If I am running the compiled program by itself, the printer output

uses a
smaller font which apparently is proportional and the result is very

ragged
looking as nothing lines up.

3. When I tried using the Common Dialog Show Font method, I got an

error message
saying that no fonts were installed. (Word for Windows lists dozens

of fonts so
they must be installed and all of them appear to be TrueType.)

Does anyone has any ideas about what else I might try?


You have to tell the control which Fonts you want via the Flag property.
Assuming you named the control CommonDialog1 (the default)...

For Screen Fonts only
=======================
CommonDialog1.Flags = cdlCFScreenFonts

For Printer Fonts only
=======================
CommonDialog1.Flags = cdlCFPrinterFonts

For Both
=======================
CommonDialog1.Flags = cdlCFScreenFonts Or cdlCFPrinterFonts

Rick - MVP


Rick,
Will check that out tomorrow. Thanks.
Val Mehling
valjm16@DELETE_THISearthlink.net

XRL (Extreme Racing League) Info
http://extremeracingleague.com/
Jul 17 '05 #3
On Wed, 25 Aug 2004 12:11:18 -0400, "Rick Rothstein"
<ri************@NOSPAMcomcast.net> wrote:
Up until now I have been able to avoid using Common Dialog by

accessing printers
directly. This is no longer possible, so-

Using VB5 under XP Home Edition. I use the Common Dialog functions to

select a
printer and output my data.

1. If I am in the VB5 IDE, the printer output appears to be

non-proportional and
looks perfect because it all lines up.

2. If I am running the compiled program by itself, the printer output

uses a
smaller font which apparently is proportional and the result is very

ragged
looking as nothing lines up.

3. When I tried using the Common Dialog Show Font method, I got an

error message
saying that no fonts were installed. (Word for Windows lists dozens

of fonts so
they must be installed and all of them appear to be TrueType.)

Does anyone has any ideas about what else I might try?


You have to tell the control which Fonts you want via the Flag property.
Assuming you named the control CommonDialog1 (the default)...

For Screen Fonts only
=======================
CommonDialog1.Flags = cdlCFScreenFonts

For Printer Fonts only
=======================
CommonDialog1.Flags = cdlCFPrinterFonts

For Both
=======================
CommonDialog1.Flags = cdlCFScreenFonts Or cdlCFPrinterFonts

Rick - MVP


Problem Solved! Thanks again.
Val Mehling
valjm16@DELETE_THISearthlink.net

XRL (Extreme Racing League) Info
http://extremeracingleague.com/
Jul 17 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Vince | last post: by
3 posts views Thread by Grim Reaper | last post: by
4 posts views Thread by Tracey | last post: by
1 post views Thread by Chad Dittmer via .NET 247 | last post: by
3 posts views Thread by Alejandra Parra | last post: by
11 posts views Thread by randomtalk | last post: by
reply views Thread by Galen Somerville | last post: by
1 post views Thread by Dreamtime | last post: by
3 posts views Thread by Wilson | last post: by

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.