Click here to Skip to main content
15,913,854 members
Home / Discussions / C#
   

C#

 
AnswerRe: creating Processes to run BAT files using XCOPY Pin
Dave Kreskowiak14-Nov-07 6:46
mveDave Kreskowiak14-Nov-07 6:46 
GeneralRe: creating Processes to run BAT files using XCOPY Pin
ckelker14-Nov-07 6:58
ckelker14-Nov-07 6:58 
GeneralRe: creating Processes to run BAT files using XCOPY Pin
Dave Kreskowiak14-Nov-07 12:50
mveDave Kreskowiak14-Nov-07 12:50 
GeneralRe: creating Processes to run BAT files using XCOPY Pin
ckelker15-Nov-07 7:31
ckelker15-Nov-07 7:31 
GeneralRe: creating Processes to run BAT files using XCOPY Pin
Dave Kreskowiak15-Nov-07 12:09
mveDave Kreskowiak15-Nov-07 12:09 
QuestionCreateGraphics on a System.Image Pin
codemunkeh13-Nov-07 12:27
codemunkeh13-Nov-07 12:27 
AnswerRe: CreateGraphics on a System.Image Pin
Christian Graus13-Nov-07 12:38
protectorChristian Graus13-Nov-07 12:38 
GeneralRe: CreateGraphics on a System.Image Pin
codemunkeh13-Nov-07 12:50
codemunkeh13-Nov-07 12:50 
"You call CreateGraphics in a paint event ? Why ?"
I don't. I assure you, even 3 years of VB.NET didn't make me THAT bad. What the app does is create an instance of a class which contains a whole lot of drawing code and pass it a reference to the control it draws to.
Then it adds its own handlers for the Resize & Paint events of the control, and updates the Graphics object accordingly.
The paint event calls the drawDisplay() event, which uses the Graphics object to draw (fill) rectangles and text to the control.
The resize event is the only thing that ever calls CreateGraphics().

What I want to do is to be able to store a copy of the Image last drawn, and only necessitate that the image be redrawn when the display is scrolled. Otherwise, the paint event will simply draw the last image drawn.
I did have a Image lastImage for this, but using displayPanel.DrawToBitmap doubled my draw time and would only draw the control as a background colour.

"Graphics.FromImage"
So if I set my Graphics object like this I'll be able to use DrawString & FillRectangle to draw directly to the Bitmap in memory, then draw said Bitmap to the control using e.Graphics.DrawImage() ?

*realises how badly explained it was first time*


Ninja (the Nerd)

Confused? You will be...

GeneralRe: CreateGraphics on a System.Image Pin
Christian Graus13-Nov-07 12:59
protectorChristian Graus13-Nov-07 12:59 
GeneralRe: CreateGraphics on a System.Image Pin
codemunkeh13-Nov-07 13:05
codemunkeh13-Nov-07 13:05 
AnswerRe: CreateGraphics on a System.Image Pin
Luc Pattyn13-Nov-07 13:06
sitebuilderLuc Pattyn13-Nov-07 13:06 
GeneralRe: CreateGraphics on a System.Image Pin
codemunkeh13-Nov-07 13:09
codemunkeh13-Nov-07 13:09 
GeneralRe: CreateGraphics on a System.Image Pin
Luc Pattyn13-Nov-07 13:16
sitebuilderLuc Pattyn13-Nov-07 13:16 
GeneralRe: CreateGraphics on a System.Image Pin
codemunkeh13-Nov-07 13:35
codemunkeh13-Nov-07 13:35 
GeneralRe: CreateGraphics on a System.Image Pin
Luc Pattyn13-Nov-07 13:45
sitebuilderLuc Pattyn13-Nov-07 13:45 
QuestionImages Click Event Problem... Pin
kingletas13-Nov-07 12:01
kingletas13-Nov-07 12:01 
AnswerRe: Images Click Event Problem... Pin
Luc Pattyn13-Nov-07 12:17
sitebuilderLuc Pattyn13-Nov-07 12:17 
GeneralRe: Images Click Event Problem... Pin
kingletas13-Nov-07 12:51
kingletas13-Nov-07 12:51 
GeneralRe: Images Click Event Problem... Pin
Luc Pattyn13-Nov-07 13:11
sitebuilderLuc Pattyn13-Nov-07 13:11 
GeneralRe: Images Click Event Problem... Pin
kingletas13-Nov-07 14:58
kingletas13-Nov-07 14:58 
QuestionImporting Extreamly Large Files Pin
jasper01813-Nov-07 11:58
jasper01813-Nov-07 11:58 
GeneralRe: Importing Extreamly Large Files Pin
jasper01813-Nov-07 12:46
jasper01813-Nov-07 12:46 
QuestionDateTime Compare Problem Pin
dataminers13-Nov-07 11:12
dataminers13-Nov-07 11:12 
AnswerRe: DateTime Compare Problem Pin
Christian Graus13-Nov-07 11:35
protectorChristian Graus13-Nov-07 11:35 
GeneralRe: DateTime Compare Problem Pin
dataminers13-Nov-07 11:45
dataminers13-Nov-07 11:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.