Hello,
I'm doing an analog clock windows forms application in Visual C++, and for this I need to draw a few lines in a blank space inside the form.
I've searched the Net but can't find a simple way to draw inside a form window.

Any Ideas?

Ok, I found that in the properties of Form1 you can create a new event "Paint". But now I'm lost in one thing, how to make this event run every timer tick?

>>how to make this event run every timer tick?

OMG you don't want to do that! If you did it would consume all the CPU time that your computer has, leaving nothing for any other programs.

Most likely what you meant was on every second. Timer ticks and seconds are very different things. There are (usually) 1,000 ticks per second.

As for your question, I don't know the answer because I don't do managed c++.

Edited 6 Years Ago by Ancient Dragon: n/a

Well I have a timer object which is set to "tick" every 1000ms. But I don't know how to make this timer run the paint event.

I think I got it! It's the Invalidate() function which redraws the paint event.

This question has already been answered. Start a new discussion instead.