Thanks. I got it. I thought I can only copy one row or column at a
time. I did not realize I can copy the whole row downwards.
> In B2 enter this formula:
>
[quoted text clipped - 34 lines]
>
> > Du
Gord Dibben - 27 Jan 2008 20:57 GMT
If you are interested, here is a macro that will do the same thing without
formulas or the numbers in Row 1 or Column A
Sub FillNums()
'to fill rows and columns with numbers from 1 to whatever
'across or down
Dim nrows As Integer
Dim ncols As Integer
On Error GoTo quitnow
RowsorCols = InputBox("Fill Across = 1" & Chr(13) _
& "Fill Down = 2")
Num = 1
nrows = InputBox("Enter Number of Rows")
ncols = InputBox("Enter Number of Columns")
If RowsorCols = 1 Then
For across = 1 To nrows
For down = 1 To ncols
ActiveSheet.Cells(across, down).Value = Num
Num = Num + 1
Next down
Next across
Else
For across = 1 To ncols
For down = 1 To nrows
ActiveSheet.Cells(down, across).Value = Num
Num = Num + 1
Next down
Next across
End If
quitnow:
End Sub
Gord Dibben MS Excel MVP
>Thanks. I got it. I thought I can only copy one row or column at a
>time. I did not realize I can copy the whole row downwards.
[quoted text clipped - 37 lines]
>>
>> > Du
Pete_UK - 28 Jan 2008 09:04 GMT
Glad to be of help.
Pete
On Jan 27, 8:37 pm, "duzhid...@gmail.com" <duzhid...@gmail.com> wrote:
> Thanks. I got it. I thought I can only copy one row or column at a
> time. I did not realize I can copy the whole row downwards.
[quoted text clipped - 39 lines]
>
> - Show quoted text -