Excel linking cells

Hidden999

New Member
Joined
Mar 3, 2019
Messages
18
Hi guys,

I am making a worksheet and have a question regarding linking cells.

What I want to achieve:
Having two cells (on different sheets or not) which contain the same text.
So if I change the text in one cell it also changes in the other cell. Vice versa.
I've tried doing it just like this.

A1 contains formula (=B1)
B1 contains formula (=A1)

But then if you type it overwrites the formula.

Thanks in advance!
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Hi & welcome to MrExcel
The only way to do that would be with VBA, is that an option?
 
Last edited:
Upvote 0
Thank you for your quick reply! To be fair I'm a noob in Excel so it won't be a problem if I understand how it works. Don't know if it's difficult?
 
Upvote 0
Ok, what cells do you want to link?
 
Upvote 0
Well I want to link quite some cells together. Also between 2 different sheets. Maybe it's possible to give a small instruction on how to make this happen?
 
Upvote 0
What are the cells that you want to link & what are the sheet names?
 
Upvote 0
For example A1 on sheet (Idontknow) with A1 on sheet (noobinexcel).

I haven't made the full format yet. So if you can give an example of what the code looks like.
 
Upvote 0
In the noobinexcel sheet put
Code:
REMOVED
& in the other put
Code:
REMOVED
change values in red to your actual sheet names.
This will work for the whole of column A.
To see how to add code to a Worksheet module have a look here https://www.contextures.com/xlvba01.html
 
Last edited:
Upvote 0
Cheers mate you are a legend. So that works for the column A. What if I would like row just row 1 or maybe even just one cell like row one column A?
 
Upvote 0
Please do not use the code I originally posted as it's seriously flawed
The two sets of code should be
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
   If Target.Column = 1 Then
      Application.EnableEvents = False
      Sheets("[COLOR=#ff0000]Idontknow[/COLOR]").Range(Target.Address).Value = Target.Value
      Application.EnableEvents = True
   End If
End Sub
and
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
   If Target.Column = 1 Then
      Application.EnableEvents = False
      Sheets("[COLOR=#ff0000]noobinexcel[/COLOR]").Range(Target.Address).Value = Target.Value
      Application.EnableEvents = True
   End If
End Sub
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,817
Messages
6,181,149
Members
453,021
Latest member
Justyna P

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