The code below assumes that you have a userform with two text boxes and a command button. I've also got a fairly limited number of rows of data that I'm working with.
Code:
Private Sub CommandButton1_Click()
Call AmendSheet
End Sub
Private Sub UserForm_Activate()
For i = 2 To 6
If ActiveCell.Row = i Then
TextBox1.Text = Cells(i, 1)
TextBox2.Text = Cells(i, 2)
End If
Next i
End Sub
Private Sub UserForm_Click()
End Sub
Private Sub AmendSheet()
For i = 2 To 6
If ActiveCell.Row = i Then
Cells(i, 1) = TextBox1.Text
Cells(i, 2) = TextBox2.Text
End If
Next i
End Sub
Obviously, you'll need to include some sort of error-handling for users who haven't selected a cell in a used row, as well as finding the maximum number of used rows.