Posted on: 5/8/2015 9:42:24 AM | Views : 705

Hi,
I just want to ask how to set a width of strings so that they can be aligned like a list with columns.
Dim order_lines As New StringBuilder Dim i As Integer For i = 0 To row.GetUpperBound(0) Dim product As String = row(i)("ProductName").ToString.PadRight(10) Dim quantity As String = row(i)("ProductQty").ToString.PadRight(5) order_lines.Append(product & quantity & Environment.NewLine) Next i The result of this code is:
Smartphone   72 Tablet   41 Memory Sticks   50
And it musst be:
Smartphone          72 Tablet                   ...

Go to the complete details ...