473,407 Members | 2,598 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Force printing in Black and white

Is there a way to force printing in black and white programatically?
Dec 6 '07 #1
3 5023
Brian,

Are you in control of the application, or are you trying to do this
through another application?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Brian Cook" <br********@bnsf.comwrote in message
news:E3**********************************@microsof t.com...
Is there a way to force printing in black and white programatically?
Dec 6 '07 #2
Yes I am developing the application.

The customer wanted the RichTextBox background as Black, and the text in
Green. Printing is ugly with those color choices.
"Nicholas Paldino [.NET/C# MVP]" wrote:
Brian,

Are you in control of the application, or are you trying to do this
through another application?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Brian Cook" <br********@bnsf.comwrote in message
news:E3**********************************@microsof t.com...
Is there a way to force printing in black and white programatically?
Dec 7 '07 #3
On Fri, 07 Dec 2007 07:24:02 -0800, Brian Cook <br********@bnsf.comwrote:
Yes I am developing the application.

The customer wanted the RichTextBox background as Black, and the text in
Green. Printing is ugly with those color choices.
You can set the PageSettings.Color property to false when printing to
disable color printing.

However, keep in mind that this isn't going to change "ugly" into
"pretty". :) In the example you offer, one of two things will happen:

1) the printout will be converted to grayscale
2) the printout will be "posterized" (or quantized...basically, colors
converted to some closest matching shade of gray, possibly selected only
from black and white)

What happens exactly probably depends on the printer. Even in case #1,
you may find the text difficult to read, because green will come out as
some shade of gray. In case #2, green could actually get mapped to black,
making the text invisible.

IMHO, for situations like this, if you care about the quality of the
printout you need to add custom-handling code to change the colors before
printing so that you get a more readable printout. Depending on what
you're printing, you may have to modify the object being printed itself,
create a cloned object used for printing, or just include
printing-specific logic inside the object's drawing code.

As a first pass, you might just disable any background coloring when
printing. This will address most of the basic contrast issues you might
run into, and is a fairly common technique. It has the added benefit of
reducing ink/toner consumption (less ink is especially helpful, not just
because of the cost but also because you won't get a soggy mess of a
printout :) ).

Of course, make the behavior controllable by the user. You never know
when you'll have a user that really wants bad-looking printouts. :)

Pete
Dec 7 '07 #4

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

Similar topics

4
by: Arif | last post by:
I C# code prints very slow as compared to a third party barcode printing software. That software prints approximately 10 labels in 2 seconds while my C# code prints 10 labels in 5 to 6 seconds. And...
0
by: Mark Davison | last post by:
Hi, I hope someone can help, this has been driving me mad! I am trying to generate a graphic on the fly. This is then shown in the browser in a "print preview" type window. The user can click a...
4
by: Brett Baisley | last post by:
Can someone tell me where to find the setting to print all print outs in black and white, instead of trying to print out in color? I can't find it in Options
0
by: Phil Galey | last post by:
I'm printing to a DeskJet 5550 printer. From WordPerfect, if I have a color document and I specify grayscale in the printer properties dialog, it prints in grayscale as expected. However, from...
1
by: Dreamtime | last post by:
Hi I am using Visual Studio 2005 and the bundled Crystal Reports (previously I used .net 2003 and bundled Crystal Reports for 2 years - same issues!) I have a report which is displayed in the...
5
by: kaosyeti | last post by:
how can i get my report to print all in black when i have a control with conditional formatting to change the font color about 10% of the time it shows up. i've been trying to find a way to format...
1
by: Sandy | last post by:
Dear Pythonic People, I recently discovered SciTE (1.68) as a programming editor, and I find it just beautiful. Small, fast, elegant and beautiful. I particularly like syntax highlighting...
3
by: billelev | last post by:
Hi there, I have some code that prints a report to a pdf driver (Adobe). I am using this code on two different machines, and hence two different installations of Access. On one machine the pdf...
3
by: jabslim via DotNetMonster.com | last post by:
i want to print files in vb.net with the ability to let users choose if they want it "colored" or only "black and white"(grayscale). how can i make a file print in only "black and white"? ill...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
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...

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.