Changing Cell Value on Different Tabs

OldSwimmer1650

New Member
Joined
Dec 3, 2020
Messages
38
Office Version
  1. 365
Platform
  1. Windows
I want to change multiple cell values on different tabs.

Let:
Cell A1 on Tab1
Cell B1 on Tab2
Cell C1 on Tab3

When I enter a value into any of the cells (A1, B1, C1) the other cells change to the same value.
So, If I enter 5 into cell C1 on Tab3, Cells A1 & B1 change to 5.
If I enter 10 into cell A1 on Tab1, Cell B1 & C1 change to 10.

Seems easy but I've no idea.
 

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.
Sounds like some VBA should handle it. Though you will need a Worksheet_Change event on each sheet to do the job. Is VBA an option?
 
Upvote 0
Then give these a try:
Tab 1 code
VBA Code:
Sub Worksheet_Change(ByVal Target As Range)
'Sheet1
Dim wsB, wsC As Worksheet
Set wsB = Sheets("Sheet2")
Set wsC = Sheets("Sheet3")
Application.EnableEvents = False
If Not Intersect(Target, Range("A1")) Is Nothing Then
    wsB.Range("B1") = Range("A1")
    wsC.Range("C1") = Range("A1")
End If
Application.EnableEvents = True
End Sub

Tab 2 code
VBA Code:
Sub Worksheet_Change(ByVal Target As Range)
'Sheet2
Dim wsA, wsC As Worksheet
Set wsA = Sheets("Sheet1")
Set wsC = Sheets("Sheet3")
Application.EnableEvents = False
If Not Intersect(Target, Range("B1")) Is Nothing Then
    wsA.Range("A1") = Range("B1")
    wsC.Range("C1") = Range("B1")
End If
Application.EnableEvents = True
End Sub

Tab 3 code
VBA Code:
Sub Worksheet_Change(ByVal Target As Range)
'Sheet3
Dim wsA, wsB As Worksheet
Set wsA = Sheets("Sheet1")
Set wsB = Sheets("Sheet2")
Application.EnableEvents = False
If Not Intersect(Target, Range("C1")) Is Nothing Then
    wsA.Range("A1") = Range("C1")
    wsB.Range("B1") = Range("C1")
End If
Application.EnableEvents = True
End Sub
 
Upvote 0
Then give these a try:
Tab 1 code
VBA Code:
Sub Worksheet_Change(ByVal Target As Range)
'Sheet1
Dim wsB, wsC As Worksheet
Set wsB = Sheets("Sheet2")
Set wsC = Sheets("Sheet3")
Application.EnableEvents = False
If Not Intersect(Target, Range("A1")) Is Nothing Then
    wsB.Range("B1") = Range("A1")
    wsC.Range("C1") = Range("A1")
End If
Application.EnableEvents = True
End Sub

Tab 2 code
VBA Code:
Sub Worksheet_Change(ByVal Target As Range)
'Sheet2
Dim wsA, wsC As Worksheet
Set wsA = Sheets("Sheet1")
Set wsC = Sheets("Sheet3")
Application.EnableEvents = False
If Not Intersect(Target, Range("B1")) Is Nothing Then
    wsA.Range("A1") = Range("B1")
    wsC.Range("C1") = Range("B1")
End If
Application.EnableEvents = True
End Sub

Tab 3 code
VBA Code:
Sub Worksheet_Change(ByVal Target As Range)
'Sheet3
Dim wsA, wsB As Worksheet
Set wsA = Sheets("Sheet1")
Set wsB = Sheets("Sheet2")
Application.EnableEvents = False
If Not Intersect(Target, Range("C1")) Is Nothing Then
    wsA.Range("A1") = Range("C1")
    wsB.Range("B1") = Range("C1")
End If
Application.EnableEvents = True
End Sub
TYVM!
I'll give this a try later today when I get some free time. Some of this VBA code is new to me so I may have a couple of questions.
 
Upvote 0

Forum statistics

Threads
1,223,895
Messages
6,175,257
Members
452,625
Latest member
saadat28

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top