Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

out of memory

Posted on 2014-03-25
2
Medium Priority
?
187 Views
Last Modified: 2014-03-31
I've the following error:

System.OutOfMemoryException: Memoria insuficiente.
   en System.Drawing.Graphics.CheckErrorStatus(Int32 status) (see attached file)

It occurs when the user clicks a button continuously and fast (the button is disabled at first click) and show the next form. It seems that the error is triggered when the form is loading the background image.

How can I fix that? Need more info?

thanks in advance,
Leonel
dump.txt
0
Comment
Question by:leorocha
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 22

Accepted Solution

by:
Ivo Stoykov earned 1500 total points
ID: 39955362
there is a bug in GDI+ and there is a workaround

image = image.GetThumbnailImage(image.Width, image.Height, null, IntPtr.Zero);

Open in new window

look here
HTH

Ivo Stoykov
0
 

Author Comment

by:leorocha
ID: 39955837
Thanks for your response Ivo. I've seen this WA. At this moment, the background picture is defined in the form property BACKGROUNDIMAGE in the VS IDE. Do you mean I use Form.BackgroundImage=myimage.GetThumbnailImage(myimage.Width, myimage.Height, null, IntPtr.Zero) in FORM LOAD EVENT instead?
0

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question