I am trying to print out a table using the printer.print format. I am able top print it out but I am having problems trying to align the numbers so that it would actually look like a table. Could anyone help me please?


Private Sub Form_Load()

Dim x(19), y(19), J, I, H


x(1) = -0.3327
x(2) = -0.2728
x(3) = -0.2129
x(4) = -0.1538
x(5) = -0.0946
x(6) = -0.0184
x(7) = 0.0639
x(8) = 0.1712
x(9) = 0.3216
x(10) = 0.472
x(11) = 0.6832
x(12) = 0.8945
x(13) = 1.1997
x(14) = 1.5588
x(15) = 1.9999
x(16) = 2.6618
x(17) = 3.3238
x(18) = 3.4853
x(19) = 3.5947

y(1) = -59.9633
y(2) = -49.1658
y(3) = -38.3808
y(4) = -27.7159
y(5) = -17.0509
y(6) = -3.3256
y(7) = 11.5336
y(8) = 30.8618
y(9) = 57.9692
y(10) = 85.0776
y(11) = 123.1507
y(12) = 161.2238
y(13) = 216.2347
y(14) = 280.9682
y(15) = 360.4672
y(16) = 479.7774
y(17) = 599.0876
y(18) = 628.1966
y(19) = 647.9225




For J = 1 To 2
Printer.Print " HA Load on Lane No."; J
Printer.Print " | Beam No. | Distribution Coeff. | L.L.Moment |"
Printer.Print " ----------- --------------------- -------------"
For I = 1 To 19


Printer.Print " | " + Format$(I, "00") + " | " + Format$(x(I), "000.0000;-00.0000") + " | " + Format$(y(I), "000.000;-00.000") + " | "

Next I
Next J

Printer.EndDoc
End Sub