Hello all,
I am populating a spreadsheet with data from access file. I am splitting each record into two lines so that it writes on two lines(some of the records writes on one row and the other half writes on the next row. I am doing this because some of the length of the records are pretty long to fit on one line. However, data in the second row bunches up in the first cell(column A) and doesn't spread out, making the height of that row to be extremely large, disfiguring the look of the spreadsheet.
What code I use to expand that second row so that the records spread out to other unused cells?
This is the code that generates the record I need to spread out to other cells.
xlWksht.Cells(ii + 1, 1).value = "'" & rsin![Comments]
Below is the code that populates the spreadsheet:
Do Until rsin.EOF = True ii = ii + 2 xlWksht.Cells(ii, 1).value = rsin![Req No] xlWksht.Cells(ii, 2).value = rsin![Description] xlWksht.Cells(ii, 3).value = rsin![P L] & Chr(10) & rsin![Pgmr2] & Chr(10) & rsin![Pgmr3] xlWksht.Cells(ii, 4).value = rsin![ClientName] & Chr(10) & rsin![Status] xlWksht.Cells(ii, 5).value = "-" & Chr(10) & rsin![Per Hrs] xlWksht.Cells(ii, 6).value = rsin![Hours] & Chr(10) & rsin![Tot Hrs] xlWksht.Cells(ii, 7).value = rsin![Start Date] & Chr(10) & rsin![Start Date] xlWksht.Cells(ii, 8).value = rsin![End Date] & Chr(10) & rsin![End Date] xlWksht.Cells(ii + 1, 1).value = "'" & rsin![Comments]
rsin.MoveNext
Loop
tgifgemini.