Click here to Skip to main content
15,887,304 members
Please Sign up or sign in to vote.
3.50/5 (3 votes)
See more: , +
How can we set the space between lines in an rdlc textbox?
Scenario: The application shall be printing a report to a pre-printed stationary sheet. One string field of the report is usually having about 400 characters of data (description input by user), which shall be printed in multiple lines.
As a workaround to the problem of not able to set LineHeight property of textbox control in rdlc, I have written a custom code which will insert new line characters into the string (by adding Environment.NewLine) such that the string is splitted into multiple lines.
However, I am not able to set the space between each line in the text box. I have tried setting both SpaceAfter and SpaceBefore property. No change :-(
I also tried using VbCrLf and combination of Chr(10) and Chr(13) instead of Environment.NewLine. Did not help... Can you help!!!
I am using VS2010 Premium Edition and Application Target of 4.0 framework.
Posted

1 solution

To set spacing between each line in the textbox. Right click the textbox and select properties, then the Font section. In the Line Spacing area select custom and put a 9pt, the higher the number, the more spacing you will have.
 
Share this answer
 
Comments
Mandani Navneet 3-Sep-15 3:05am    
spacing between line is not work. can you tell me something another solution.
Contenderia 23-Sep-21 3:26am    
does not work for me

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900