cell formula default

bsb2013

New Member
Joined
Jul 16, 2010
Messages
31
Lets say that I want column A+ column B to always equal 2, so if I enter 0 in b1 then A1 becomes 2 then if I change A1 to 1, b1 becomes 1. Is there a way to do this without vba?
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
Use the Worksheet_Change event, and check to see if cells A1 or B1 changed. If so, change the other one. (Remember to disable events in the code, otherwise you'll create a never-ending loop of change events.)
 
Upvote 0
VoG, the user wants to be able to type a number into a cell that already has a formula and maintain that formula, which I'd love to see an example of without using VBA.

In A1 if you have:
=2-B1

And in B1 if you have:
=2-A1

You create a circular reference, which can be accommodated using iterations, yes. However you cannot overwrite A1 and expect the formula in A1 to re-appear if you then change B1 without VBA.
 
Upvote 0

Forum statistics

Threads
1,224,586
Messages
6,179,729
Members
452,939
Latest member
WCrawford

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