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
  •  | 
  •  

문제

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.)

도움이 되었습니까?

해결책

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.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top