Skip to main content

Add Character to end of string

This code snippet can be used instead of the LeaderDots property from the 2009 reports.

Code

Public Function AppendToEnd(ByVal Value As String, ByVal StringToAdd As String, ByVal UntilLength As Integer) 
While(Value.Length < UntilLength)
Value = Value + StringToAdd
End while
Return Value
End Function

How to (Example in Report 104)

  • First add the following code to the Code property Properties Window Code
  • Then use the function in the wished Text Box Expression Properties Window Code
  • The final result is looking like this
BeforeAfter
BeforeAfter