Solved automatically post data from one cell to another

Microsoft Office 2010 professional
March 16, 2012 at 07:59:39
Specs: Windows 7
automatically post data data from one cell/another in Excel 2010.
I would like to automatically update data from one cell to another within the same worksheet.
I need to post a name from one cell to another even when I change the name in the orginal cell by drag/dropping I need the target cell to update automatically.

See More: automatically post data from one cell to another

Report •


#1
March 16, 2012 at 08:41:23
✔ Best Answer
If the original cell is A1, and the target cell is B1, this code will update B1 if you change A1 by a Drag and Drop.

Private Sub Worksheet_Change(ByVal Target As Range)
  If Target.Address = "$A$1" Then Range("B1") = Target
End Sub

Right-Click the sheet tab for the sheet you want this to happen in and choose View Code.

Paste that code into the pane that opens.

Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.


Report •

#2
March 26, 2012 at 04:06:45
DerbyDad03:
Sorry for the late reply I was out all last week. The code worked great for 1 cell how can I list several cells? I tried and/or and I received a syntax error.

Thanks for your help.


Report •

#3
March 26, 2012 at 07:19:55
I would need more information related to the "several cells", such as the source and destination before I could offer any more suggestions.

Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.


Report •

Related Solutions


Ask Question