ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   How to link two cells and when you update one it updates the other (https://www.excelbanter.com/excel-worksheet-functions/239997-how-link-two-cells-when-you-update-one-updates-other.html)

b46ygurl

How to link two cells and when you update one it updates the other
 
Is it possible to link two cells and when you update one it automatically
updates the other?

Jacob Skaria

How to link two cells and when you update one it updates the other
 
There is no need to multi-post in these newgroups..

---Using formulas you can link one cell to another. In B1 use the formula
=A1
to link B1 to A1...Any changes made to A1 will be reflected in B1

---If you are looking to reflect changes made in A1 and B1 to reflect in
both cells you will need to use a macro. Right click the sheet tab view code
and paste the below code.

Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
If Not Application.Intersect(Target, Range("A1")) Is Nothing Then _
Range("B1") = Range("A1")
If Not Application.Intersect(Target, Range("B1")) Is Nothing Then _
Range("A1") = Range("B1")
Application.EnableEvents = True
End Sub


If this post helps click Yes
---------------
Jacob Skaria


"b46ygurl" wrote:

Is it possible to link two cells and when you update one it automatically
updates the other?



All times are GMT +1. The time now is 07:21 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com