Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7956849
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T04:07:01+00:00 2026-06-04T04:07:01+00:00

Ive searched some fo a solution but not a single person shows a solution…

  • 0

Ive searched some fo a solution but not a single person shows a solution… I would appreciate if someone could explain why it occurs and how to solve it (in a simple way) 🙂

Occurs in same place all the time… a couple of minutes after i start the program.

private static Bitmap bmpScreenShot;
private static Graphics gfxScreenShot;
...
...

bmpScreenShot = new Bitmap(Screen.PrimaryScreen.Bounds.Width,
    Screen.PrimaryScreen.Bounds.Height, PixelFormat.Format32bppArgb);
gfxScreenShot = Graphics.FromImage(bmpScreenShot);
gfxScreenShot.CopyFromScreen(Screen.PrimaryScreen.Bounds.X,
    Screen.PrimaryScreen.Bounds.Y, 0, 0, Screen.PrimaryScreen.Bounds.Size, 
    CopyPixelOperation.SourceCopy); // <-- Occurs here a while after ive started the application

It runs a couple of times (say 40-80 times) before this happens:

Win32Exeption was unhandled: The operation completed successfully

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T04:07:03+00:00Added an answer on June 4, 2026 at 4:07 am

    Turns out i had to do bmpScreenShot.Dispose(); and gfxScreenShot.Dispose();

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've searched for an answer and found some c#-examples, but could not get this
I've searched around, and saw some tips, but still couldn't find the solution to
Ive searched the internet, but found nothing pertaining to my question. From the link
I've searched already for some ideas on this but the answers were totally code-based;
I've searched the whole day for a solution of my problem, but didn't find
I've searched a lot, but didnt found the solution to capture the audio recorded
I've searched here and the web for a solution, but they just seem to
I've searched the Internet and have found some good solutions for teeing STDOUT to
I'm trying to build a fixed menu like the image. I've searched for some
I've read through some of docs, I've searched for sample concepts, and I'm still

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.