Welcome Guest.

2Answers

How can I add a bitmap using the MFC project created by VS2017?

Asked by: Charles Roberts 185 views IT August 27, 2018

After adding a Bitmap, I want to insert a picture of a black piece, but I don't want to draw a piece myself, so I want to save the picture of a black piece directly. I don't know how to get it. Please ask everyone. Thank you very much.

Addition: There really is no big god to help solve it. . .

2 Answers

  1. +7Votes  

    This depends on the purpose of your final bitmap and the type of project

    If you are based on a dialog box, you can load the image you want directly with the picture control control. Bitmap

    If you want to put a resource file, you can import it directly

    Question: I click import Then there was a screenshot of yours, but why did the image I saved on the desktop not show up? The image has been formatted beforehand. Is there a problem with my VS?

    Answer: What is the format of your picture? Resource files only support bmp/ico files by default.
    You can also choose the file suffix as *.*
    Either you can import .bmp or .ico directly
    (It shows the importable suffix is ​​indeed a problem)

    Nancy- August 27, 2018 |

  2. +3Votes  

    VC built-in tools seem to be 16 colors can not be used, generally use RC resource files, import outside edited pictures, RC resource files The editor VS can also be edited.

    Question: How can I use VS to import images edited outside? For example, I want to write a backgammon wishing to import a landscape map to change its background. I can’t draw a background myself.

    Answer: The landscape map is to import your resource files. The background image is drawn on the window. VS imports the edited image outside. It is very simple. Just open the resource file with VS and you can operate it. Without the resource file, you can add and create a

    Diane King- August 28, 2018 |