Cell entry


S

Sudipta Sen

Want to input data A1, B1 & C1 on sheet 1, which will be save / store on
sheet 2 at A1,B1, and C1, again I want to input new data on sheet 1 at A1,B1
and C1 which will be automatically save / store on Sheet 2 at A2, B2, and C2,
repeatedly I want to input another new data on sheet 1 at A1, B1, & C1, whcih
will be again save on sheet 2 at A3, B3, & C3 and so on.
Means input cell (A1) on sheet 1 will be same but output data on sheet 2
will be A1,A2,A3 and so on.

Rdgss........Sudipta
 
Ad

Advertisements

J

Jarek Kujawa

Press ALT+F11 to get to VBA
in Project - VBAProject window double click on Sheet1
select Worksheet_Change event (or paste the following code)

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$1" Then Worksheets("Sheet2").Range("A" &
WorksheetFunction.CountA(Worksheets("Sheet2").Range("A:A")) + 1) =
Target.Value
ElseIf Target.Address = "$B$1" Then Worksheets("Sheet2").Range("A" &
WorksheetFunction.CountA(Worksheets("Sheet2").Range("A:A")) + 1) =
Target.Value
ElseIf Target.Address = "$C$1" Then Worksheets("Sheet2").Range("A" &
WorksheetFunction.CountA(Worksheets("Sheet2").Range("A:A")) + 1) =
Target.Value
End If
End Sub
 
Ad

Advertisements

J

Jacob Skaria

Hi Sudipta

Try the below

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Row = 1 And Target.Column <= 3 Then
If Target.Text <> "" Then _
Sheets("Sheet2").Cells(Rows.Count, _
Target.Column).End(xlUp).Offset(1) = Target.Text
End If
End Sub

If this post helps click Yes
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top