转自“一堆好大的垃圾啊”的博客
Image myImage = new Bitmap(600,400);
Graphics g = Graphics.FromImage(myImage);
g.CopyFromScreen(new Point(Cursor.Position.X - 150, Cursor.Position.Y - 25), new Point(0, 0), new Size(600, 400));
IntPtr dc1 = g.GetHdc();
g.ReleaseHdc(dc1);
this.pictureBox1.Image = myImage;
myImage.Save("c:\\1.jpeg");
posted on 2010-10-13 13:33  Jessica Lu  阅读(196)  评论(0)    收藏  举报