Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void CapFullscreen()
- {
- var image = ScreenCapture.Fullscreen();
- string file = Path.GetTempFileName().Replace(".tmp",".png");
- try
- {
- image.Save(file, System.Drawing.Imaging.ImageFormat.Png);
- System.Diagnostics.Process.Start(file);
- }
- catch (Exception ex)
- {
- MessageBox.Show(ex.Message, "Fatal error");
- }
- finally
- {
- image.Dispose();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment