assuming the ID's are fixed length, something like this should do it:
This isn't the most accurate way of doing it, but unless you only have a few rows of data it is the best you can do in a list box (you could always use a grid instead!)VB Code:
List2.Clear max_len = [b]{length of longest string that can be returned for rs!Name}[/b] Do While Not rs.EOF ... List2.AddItem " " & rs!ID & " " & vbtab _ & formatDate & " " & vbtab _ & FormatTime & " " & vbtab _ & rs!Name [b]& space ((max_len-rs!Name)*3) [/b]& " " & vbtab _ & rs!History ...




Reply With Quote