?
Solved

Monochrome monitor

Posted on 2002-06-03
7
Medium Priority
?
287 Views
Last Modified: 2008-03-06
Hi,

I have a picture box with a certain BMP.
If I'm running my application in Monochrome monitor, the picture became totally black, but if I'm opening the same BMP in Paint application it looks good (all colors are transformed to grey colors)

How can I display the picture in VB ?

Many thanks
0
Comment
Question by:amavr
[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
7 Comments
 
LVL 1

Expert Comment

by:Toad224
ID: 7052614
geez... who has a monochrome monitor.. lol...  If the bitmap is supposed to be a color one, try opening it up in Paint again, and choosing Save As, and in the Save Type as box, try the different settings available...  Monochrome, 16 color, 256 color, 24-bit... and save the file, and try opening the new saved file with VB.

If you're not looking to display a specific bitmap, and perhaps letter the user choose one to open, you should look at the WinAPI functions for other methods of displaying bitmaps instead of using the picturebox in VB.

I hope that helps.  Good luck!
0
 

Author Comment

by:amavr
ID: 7053303
The Monochrome monitor is in use in medical applications.

I do need to load many different BMP's and JPG's dynamically - the pictures created while the program is running so I cannot use SaveAs option.

thanks
0
 

Expert Comment

by:jonnyfunfun
ID: 7056592
I would have to agree with Toad...you may be better off looking into API functions rather than using the picturebox.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 1

Expert Comment

by:Toad224
ID: 7056788
hmm... really?  There are actually medical devices that run Windows with VB programs...

Does the picture display correctly in Internet Explorer?  If it does, I suppose you could use the Internet Explorer ActiveX control.  What other ways have you tried displaying it?  Does it display properly in any other programs you have tried?
0
 
LVL 18

Expert Comment

by:mdougan
ID: 7057152
Well, there is a difference between monochrome and greyscale.  Monochrome means one single color or shade.  So, VB is going to look at the bitmap and ask if each pixel is closer to white or black, and then turn the pixel to that.  

If you need the bitmap to look good under Monochrome, then as Toad224 suggested, bring the bitmap into Paint and reduce the colors to Monochrome.  It's likely that paint will do a better job of the conversion than the picturebox control would.

If you want to have a color bitmap for people with color monitors, and a black and white one for monochrome monitors, then you'd probably want to use two separate bitmaps and then check the system's display properties before loading the bmp to decide which one to load.
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7851443
Hi amavr,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Refund points and save as a 0-pt PAQ.

amavr, Please DO NOT accept this comment as an answer.
EXPERTS: Post a comment if you are certain that an expert deserves credit.  Explain why.
==========
DanRollins -- EE database cleanup volunteer
0
 

Accepted Solution

by:
SpideyMod earned 0 total points
ID: 7912930
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
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…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Suggested Courses
Course of the Month14 days, 8 hours left to enroll

770 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