 |
|
ช่วยดูโค้ดการใช้งาน GraphicsPath C# ให้หน่อยคับ รันแล้วมันมี Error คับ |
|
 |
|
|
 |
 |
|
รบกวนช่วยดูให้โค้ดการใช้งาน GraphicsPath ให้หน่อยคับ พอดีลองเขียนรันไม่ได้อ่ะ Errors ตามรูปคับ
ขอบคุณคับ

Code (C#)
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ww
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Paint(object sender, PaintEventArgs e)
{
Graphics g = e.Graphics;
GraphicsPath gp = new GraphicsPath();
gp.AddLine(20, 25, 55, 66);
gp.AddLine(66, 55, 78, 97);
gp.AddBezier(78, 97, 56, 78, 112, 78, 123, 322);
gp.AddLine(123, 322, 100, 160);
g.DrawPath(Pens.Red, gp);
}
}
}
Tag : C#
|
|
 |
 |
 |
 |
Date :
2012-11-04 23:46:12 |
By :
นัย |
View :
1260 |
Reply :
2 |
|
 |
 |
 |
 |
|
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
GraphicsPath มันคือ Library หรือว่าอะไร แล้ว Import หรือ Add Reference แล้วหรือยังครับ 
|
 |
 |
 |
 |
Date :
2012-11-05 08:34:02 |
By :
mr.win |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
ขอบคุณคับ แก้ error ได้แล้วคับ error เพราะ ไม่ได้ Add Reference >>> using System.Drawing.Drawing2D; คับ แต่ปัญหาตอนนี้คือรันแล้วมันไม่มีรัยขึ้น ขึ้นแต่หน้า Form เปล่า
|
 |
 |
 |
 |
Date :
2012-11-05 09:16:41 |
By :
นัย |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
|
|