c# - "A generic error occurred in GDI+" while using MeasureString -


i have overriden (winforms) memoedit control (unfortunately can't give code). if enter more 32000 characters, raises error "a generic error occurred in gdi+" thought there's error (exception) in control tested on simple winform application code:

var mystring = new string('g', 32001); var g = this.creategraphics(); g.measurestring(mystring, font, 1000); 

and crashes same error know why happens or specified constant of 32000 ? couldn't find useful on google.

this seems new bug introduced in windows 8. curious behaviour in older version of windows:

https://connect.microsoft.com/visualstudio/feedback/details/776722/label-control-throws-an-exception-if-its-text-is-set-to-a-very-long-string


Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -