Solution 3 really works:
1. Convert c# code to VB.net code, add function to rdlc custom code:
Function GetText(text As String, width As Integer) As String
Dim palabras As String() = text.Split(" "c) 'text-->palabras
Dim sb1 As New System.Text.StringBuilder()
Dim sb2 As New System.Text.StringBuilder()
Dim length As Integer = palabras.Length 'palabras
Dim resultado As New System.Collections.Generic.List(Of String)()
Dim i As Integer = 0
While i < length
sb1.AppendFormat("{0} ", palabras(i)) 'palabras
If sb1.ToString().Length > width Then
resultado.Add(sb2.ToString())
sb1 = New System.Text.StringBuilder()
sb2 = New System.Text.StringBuilder()
System.Math.Max(System.Threading.Interlocked.Decrement(i), i + 1)
Else
sb2.AppendFormat("{0} ", palabras(i))
End If
System.Math.Max(System.Threading.Interlocked.Increment(i), i - 1)
End While
resultado.Add(sb2.ToString()) 'resultado
Dim resultado2 As New System.Collections.Generic.List(Of String)()
Dim temp As String
Dim index1 As Integer, index2 As Integer, salto As Integer
Dim target As String
Dim limite As Integer = resultado.Count 'resultado
For Each item As String In resultado 'resultado
target = " "
temp = item.ToString().Trim()
index1 = 0
index2 = 0
salto = 2
If limite <= 1 Then
resultado2.Add(temp)
Exit For
End If
While temp.Length <= width
If temp.IndexOf(target, index2) < 0 Then
index1 = 0
index2 = 0
target = target + " "
System.Math.Max(System.Threading.Interlocked.Increment(salto), salto - 1)
End If
index1 = temp.IndexOf(target, index2)
temp = temp.Insert(temp.IndexOf(target, index2), " ")
index2 = index1 + salto
End While
System.Math.Max(System.Threading.Interlocked.Decrement(limite), limite + 1)
resultado2.Add(temp)
Next
Dim builder As New System.Text.StringBuilder()
For Each item As String In resultado2
builder.Append(item).Append(chr(10))
Next
Return builder.ToString()
End Function
2. Call custom code in rdlc
Textbox=Code.GetText("longtext….",77)
3. Set rdlc textbox font to be one of monospace font such as BatangChe,Consolas, Courier New, DFKai-SB, DotunChe, GulimChe, GungSahChe, KaiTi,Lucida Console,MingLiU,MS Gothic,MS MinChe,NSimSun,SimHei,Simplified Arabic Fixed,SimSun,SimSun-ExtB