views:

24

answers:

2

I remember reading once that there was a way to embed an image into a code file (e.g. a screenshot or diagram) in Visual Studio, but now I can't find any reference to that feature.

Is this possible to do, or am I imagining things?

EDIT: I don't mean embed the image in the executable, for use at runtime. I mean link or embed it literally in the code, for use by developers.

A: 

You can embed images in your binary through the use of the ImageList control, which is typically used to store small icons for list controls, gridviews, etc., but could also be used for storing really any image for any purpose. A better solution would be to include a resource file and store your images there.

George
I mean I would like to have the image literally visible in the code. In my case, I'm writing geometry-related code, and I would like to include diagrams for reference for the developers.
Henry Jackson
+1  A: 

There is a plug-in for VS 2010 that can do this:

Plug-in

Paul Mrozowski
This looks like what I was remembering; I had forgotten that it was a plugin. I suppose its presence as an official VS2010 extension means it's definitely not part of the core product. Thanks!
Henry Jackson