private void toolButtonTest_Click(object sender, EventArgs e)
{
Rectangle screenRect = Screen.PrimaryScreen.WorkingArea;
using (Bitmap dumpBitmap = new Bitmap(screenRect.Width, screenRect.Height))
{
using (Graphics targetGraphics = Graphics.FromImage(dumpBitmap))
{
targetGraphics.CopyFromScreen(0, 0, 0, 0, new Size(dumpBitmap.Width, dumpBitmap.Height));
}
dumpBitmap.Save(@"e:\_test.png");
dumpBitmap.Dispose();
}
}
ASKER
The .NET Framework is not specific to any one programming language; rather, it includes a library of functions that allows developers to rapidly build applications. Several supported languages include C#, VB.NET, C++ or ASP.NET.
TRUSTED BY