I would have to make some assumptions here, based on what information you have given: such as, this control can grow dynamically to accommodate varying lengths of data?. One way to approach this would be in the Finish method (before the call to Super::Finish() ) of the control.
If your control with one line is .25 inches (base height), then in the finish get the height of the control (me.size.height) and divide by your base:
NbrLines = SafeDivide(me.size.height, .25, 0)
So if ending height is 1.25", you would have 5 lines. (Also, I used inches, but twips is the unit of measure; 1440 per inch)
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.