Right, here's what I want to do:
Have a window, with a size about 600x600. Then, have a spiral drawn on screen, but SLOWLY. So you can watch it being drawn.
I have used google, and come across a visual c# tutorial site, but for some reason, the code they show DOES NOT WORK. Whatever happens.
So, any help/code for this?
Where exactly are you stuck?
[QUOTE=ZeekyHBomb;22553386]Where exactly are you stuck?[/QUOTE]
Well, to be honest right at the start.
I know HOW to draw lines ect, but it says the class is missing or along the lines of that, even when its imported.
So I was asking for the full code.
Also want to know how to get the line to draw slowly in real-time.
Well, if someone feels like it you might get full source.
A better option would be to learn by yourself how to do it.
Since the compiler complains about your way of drawing a line, we'll start there. What's the code and the specific error?
'System.EventArgs' does not contain a definition for 'Graphics' and no extension method 'Graphics' accepting a first argument of type 'System.EventArgs' could be found (are you missing a using directive or an assembly reference?)
It's probably something stupid but still.
[code]
Pen penCurrent = new Pen(Color.Blue);
Point[] pt = { new Point( 10, 5), new Point(340, 60),
new Point(320, 148), new Point(150, 120),
new Point(24, 220), new Point(250, 150),
new Point(304, 240) };
e.Graphics.DrawBeziers(penCurrent, pt);
[/code]
Well, [url=http://msdn.microsoft.com/en-us/library/system.eventargs_members(v=VS.100).aspx]it indeed doesn't[/url].
Which event are you using that in?
You sure "e" is not meant to be System.
Ahh :ninja:
what
[QUOTE=ZeekyHBomb;22553806]Well, [url=http://msdn.microsoft.com/en-us/library/system.eventargs_members(v=VS.100).aspx]it indeed doesn't[/url].
Which event are you using that in?[/QUOTE]
I've give up now anyway. I've just brought myself an E-Book on visual c#, and am currently doing some of the programs in there.
Which will hopefully expand my knowledge on c#.
You want to use the Control.Paint event, which provides you with a PaintEventArgs, which does indeed contain a Graphics property. :eng101:
Sorry, you need to Log In to post a reply to this thread.