Once again, Hello folks!
Though i have read a number of posts on the topic, i am not finding what will fit my problem. While it is just as likely that i have looked at a good solution as not, i have yet to recognize one.
On a UserForm i have a multiline textbox. It is populated by the contents of a cell that has embedded vbCrLf in in to separate the lines for display.
I want to create a commandbutton to print out the contents of this textbox.
In order to also print out some other related information such as the date and title, i thought it best to print whatever related information i wanted to a temporary worksheet, then a few lines down, print the contents of the textbox. Using the code below does provide for each line that was separated by a vbCrLf to be on a separate line on the worksheet.
The problem i am running into is that some of the entries when within the textbox automatically wrap, but when copied to cells in the worksheet, exceed the width of a printed sheet.
I considered using another textbox on the temporary worksheet that, like the textbox on the UserForm, would automatically wrap the text, but if the contents of the textbox exceeded the height of the textbox, i presume that they would not show in the printout - am i wrong? I wouldn't want to risk truncating the information in the event that i needed to print it out. If there is a means to force the complete contents to print out, this would probably be the solution.
I am wondering if there is a different approach to this that would solve my issue. If not, i can rethink what i am doing and probably come up with something, but if there is a solution out there i would feel pretty silly trying to re-invent it...
As always, my thanks for your consideration!
Herefollows the code i am presently using prior to adding the Application.Dialogs(xlDialogPrint).Show lines
Please Login or Register to view this content.
Bookmarks