Hi,
The code below is part of a LONG macro which almost works. As I continue to test it, I find things which worked by chance, rather then from good code. I think that's the problem here.
I want to copy data from the INPUT sheet ("B" i) to the next available row in the DATA ANALYSIS sheet. While that part works, debugging tells me that sometimes I get the row number from the INPUT sheet and sometimes from the DATA ANALYSIS sheet. I would like to save the value of the row used (Pasted to) in the DATA ANALYSIS sheet so that I can write other data to that row later in the program. I've tried a few things, but w/o success.
Many thanks for any help.
Bonnie
'''''''''''''''''''''''''''''''''''''''''''' output a NEW STUDENT entry to DATA ANALYSIS
PROCESS:
Dim NextRow As Range
MsgBox "Process"
With Sheets("DATA ANALYSIS").Select
Set NextRow = .Cells(.Rows.Count, 1).End(xlUp).Offset(1, 0)
Newstudentrow = ActiveCell.Row
End With
Sheets("input").Range("b" & i).Copy
NextRow.PasteSpecial Paste:=xlValues, Transpose:=True
Application.CutCopyMode = False
Set NextRow = Nothing
'**1**
The code below is part of a LONG macro which almost works. As I continue to test it, I find things which worked by chance, rather then from good code. I think that's the problem here.
I want to copy data from the INPUT sheet ("B" i) to the next available row in the DATA ANALYSIS sheet. While that part works, debugging tells me that sometimes I get the row number from the INPUT sheet and sometimes from the DATA ANALYSIS sheet. I would like to save the value of the row used (Pasted to) in the DATA ANALYSIS sheet so that I can write other data to that row later in the program. I've tried a few things, but w/o success.
Many thanks for any help.
Bonnie
'''''''''''''''''''''''''''''''''''''''''''' output a NEW STUDENT entry to DATA ANALYSIS
PROCESS:
Dim NextRow As Range
MsgBox "Process"
With Sheets("DATA ANALYSIS").Select
Set NextRow = .Cells(.Rows.Count, 1).End(xlUp).Offset(1, 0)
Newstudentrow = ActiveCell.Row
End With
Sheets("input").Range("b" & i).Copy
NextRow.PasteSpecial Paste:=xlValues, Transpose:=True
Application.CutCopyMode = False
Set NextRow = Nothing
'**1**