开发者

Displaying overflow in footer field on a new page

I have a TextBox in the footer of my report that takes a column that can store up to 5000 characters, but the TextB开发者_JAVA技巧ox in the footer can't take 5000 characters due to its size. In my tests, the TextBox has displayed a number of chars between 1000 ('M' letters) and 1800 (dots).

I'd like a new page to be created if this field overflows, and I want the overflown part to be displayed in the footer of following pages, thus giving the column the proper space, divided in two or more pages.

Summarizing: Rather than displaying the beginning of my oversized field in my footer textbox every other page, I want the whole content of the field to be diplayed in the footer of several pages.

Note: Defining a number of characters to be displayed in the first page, and displaying the rest in other pages is not an option, because we cannot come anywhere near precision when it comes to characters and length using fixed numbers because each character has a different length.

Note2: Is more information required? I'll describe it thoroughly if you ask! Leave a comment


GDI will get you part of the way. You can use GDI's MeasureString to measure a string given a particular font. See this MSDN link

Armed with the knowledge of how big your footer area is, a custom WillStringFitInMyFooter function and a thousand bruises from your reporting tool I think you can solve this.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜