I need a function that can return an optimal height to set a richtextbox based upon it's current width and data. I would like to resize the richtextbox to display all of the content without changing the control's width.
Private Sub SetRTFHeight(byref RTF as RichtextBox)
'This function will check the current contents
'And set the proper height based upon the text
'data in RTF as well as the current width.
'In other words, do not change the width, just the
'height to accomodate the data.
'I would like the function to make the RTF just large enough
'to display all of the content without the need for scroll bars.
'Remember, some content will have carriage returns,
'and some content will just wrap naturally.
1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.
2) Installation package that will install the software (in ready-to-run condition) on the platform(s) specified in this bid request.
3) Exclusive and complete copyrights to all work purchased. (No GPL, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site).
VB.NET or C#
If you create this in C#, create a component I can call.