[Mono-dev] Howto improve Error-Messages of GDI-Functions?

latency at gmx.de latency at gmx.de
Wed Feb 28 13:42:43 EST 2007

I recently ran into a problem where Bitmap.GetPixel(int, int) threw 
ArgumentException with the Message: "Invalid Parameter. A null reference or 
invalid value was found."

As you can image, that does not help at all when debugging your application.

Therefore I've made a quick fix which helped me to have a better exception 
message (btw. the path implements behavior which is specified in MS 
documentation of GetPixel), but still, is there a way to improve the 
exceptions messages of gdi+ in general? Or do we have to do what I've done 
with GetPixel?

Kind Regards,
Valentin S.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Bitmap.GetPixel.patch
Type: text/x-diff
Size: 632 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20070228/09602e7c/attachment.bin 

More information about the Mono-devel-list mailing list