Solved

Creating In-Memory Device Context On .Net 2.0 GDI+

Posted on 2008-10-20
1
478 Views
Last Modified: 2013-12-17
I need help creating an in-memory GDI+ drawing canvas that is the Win32 equivalent of a device context with a defined width and height on which I can carry out a variety of drawing operations using GDI+ objects and methods.  The operations that I need to do include loading an image from file, drawing lines, writing text, etc. When this is completed, I need to be able to take the information from the in-memory canvas and write it out to a file or stream.

Can somebody point me in the right direction for how to go about doing this in .Net 2.0?
0
Comment
Question by:dshockey
1 Comment
 
LVL 96

Accepted Solution

by:
Bob Learned earned 500 total points
Comment Utility
You should be able to use the System.Drawing.Bitmap and System.Drawing.Graphics classes to achieve what you need.

Proof-of-concept:

Using Bitmaps for Persistent Graphics in C#
http://www.techotopia.com/index.php/Using_Bitmaps_for_Persistent_Graphics_in_C_Sharp
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Summary Displaying images in RichTextBox is a common requirement with limited solutions available. Pasting through clipboard or embedding into RTF content only support static images.  This article describes how to insert Windows control objects int…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

771 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now