Is there an alternative to any limit to the number of TextRenderer.DrawText or Graphics.DrawString in an event stack?

StackOverflow https://stackoverflow.com/questions/17603441

  •  02-06-2022
  •  | 
  •  

Question

Seems ironically appropriate for this site, I am trying to paint a bunch of text in a number of places on an overlay form, and after trying to render 16 DrawText calls the form shows a red angled cross instead of the text. Is there a better way for drawing a bunch of text on a windows form?

aka I don't want to have to learn WPF just to find that is not at all the way to go.

(note: I am going to answer this as soon as it is posted, I just found the problem solution.)

Was it helpful?

Solution

Turns out my code was throwing an index out of range error for the array of strings I was trying to draw and the eventhandler call was catching it without throwing it to the exception stack, if I am terminologying that right.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top